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 all_constraints where table_name = '<table_name>' | |
| -- where constraint_type = 'P' -> primary key | |
| -- = 'R' -> foreign keys | |
| -- = 'C' -> constraints like not null |
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 all_sequences; |
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 | |
| cols.table_name, | |
| cols.column_name, | |
| cols.position, | |
| cons.status, | |
| cons.owner | |
| from | |
| all_constraints cons inner join all_cons_columns cols on | |
| cons.constraint_name = cols.constraint_name and | |
| cons.owner = cols.owner |
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
| NSURL* url = [[NSURL alloc] initWithString: @"http://www.cnn.com"]; | |
| [[UIApplication sharedApplication] openURL: url]; |
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
| # swappiness controls the intensity of swap use, varying between 0 and 100 | |
| # this command modifies the swappiness in runtime, but the change won't persist after shutdown | |
| sudo sysctl -w vm.swappiness=0 |
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
| # to change the default folder locations in ubuntu, | |
| # just edit this file, following the instruction inside it | |
| vi $HOME/.config/user-dirs.dirs |
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
| public String getStackTrace(Exception e) { | |
| Writer stringWriter = new StringWriter(); | |
| PrintWriter printWriter = new PrintWriter(stringWriter); | |
| e.printStackTrace(printWriter); | |
| return stringWriter.toString(); | |
| } |
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
| sudo ln -s /home/your_user/.themes /root/.themes | |
| sudo ln -s /home/your_user/.icons /root/.icons | |
| sudo ln -s /home/your_user/.fonts /root/.fonts |
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 - Open the file "/opt/Adobe AIR/Versions/1.0/libCore.so". | |
| sudo vi /opt/Adobe AIR/Versions/1.0/libCore.so | |
| #2 - In vi, go to the line 16104 with the command ":16104". | |
| #3 - Find the word "firefox" (if it was your previous default browser) and replace it with "browser". | |
| # The word "browser" is not a random choice! It was chosen because it has the same size of the "firefox" word. | |
| # The size matters because we are editing a binary file and words with different sizes will cause segmentation fault # errors! | |
| #4 - Save the file and exit with the command ":wq". |
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 | |
| text | |
| from | |
| user_source | |
| where | |
| name = '<stored-procedure-name>' |
OlderNewer