This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Show all remote branches | |
| ------------------------ | |
| git branch -r | |
| Checkout remote branch: | |
| ------------------------ | |
| With newer versions, you can simply use: | |
| git fetch |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select * from DBA_PROCEDURES where OBJECT_NAME like 'PROC_NAME' ; | |
| Query to find modified DB objects | |
| ----------------------------- | |
| select object_name,object_type, max(CREATED) from USER_OBJECTS where object_type like 'PROC%' group by object_name, object_type order by 3 desc; | |
| select object_name,object_type, Created from DBA_OBJECTS where object_type like 'PROC%' and object_name = 'PROC_NAME'; | |
| DBA_OBJECTS describes all objects in the database. | |
| USER_OBJECTS describes all objects owned by the current user. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Spring is like a container of beans or factory of beans. | |
| And you ask the container to give you what you need. Container reads from some configuration setup avaialable for it & returns thw required object. | |
| BeanFactory will help create new objects by reading some configuration. | |
| We can use BeanFactory object to create target objects. And as the object is created in Bean Factory, Spring handles the life cycle of the object. | |
| spring DI | |
| BeanFactory f = new XmlBF(new FileSystemResouce(spring.xml)) | |
| f.getBean(..) | |
| ---------------------------------- | |
| BeanFactory beanFactory = new XmlBeanFactory(new FileSystemResource("C:/workspace/project/spring-demo-1/src/main/resources/spring/spring-config.xml")); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Setting log level for a class or package dynamically. | |
| ----------------------------------------------------- | |
| LoggerContext loggerContext = (LoggerContext)LoggerFactory.getILoggerFactory(); | |
| Logger rootLogger = loggerContext.getLogger("com.demo.blah1.blah2"); // class or package | |
| ((ch.qos.logback.classic.Logger) rootLogger).setLevel(Level.INFO) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. Follow the link https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ | |
| 2. While copying the link from git to add paste it into an editor, then copy paste it to the command: | |
| git remote add origin <https://github.com/user/repo.git> | |
| 3. First, pull the latest changes from repository. | |
| 4. If you get an error "fatal: refusing to merge unrelated histories" for: "git pull origin master", | |
| run: "git merge origin/master --allow-unrelated-histories" | |
| 5. Then run: "git pull origin master" | |
| 6. Finally you may run:"git push origin master" to push your changes to the repository. |