Welcome To Snipplr


Everyone's Recent SQL Snippets Tagged sql



1 ... 8 9 10 11 12 Next »
https://www.chrisjmendez.com/2008/03/23/mysql-commands-i-wish-i-could-remember/
9 127 posted 12 years ago by chrisaiv
4 109 posted 12 years ago by wolfie
An easy way to handle null dates. If date = 0000-00-00 then null, else use date
0 108 posted 12 years ago by Abe
1 114 posted 12 years ago by zingo
0 61 posted 12 years ago by Caliban
Generate the SQL necessary to create triggers that use the sequences listed above. NOTE: This particular script assumes that the tables all start with ‘tbl’. It may need to be modified to work with different naming conventions.
0 67 posted 12 years ago by thecrumb
Generate the SQL necessary to create sequences for every table. NOTE: This doesn’t create sequences. The results need to be copied and run as a script.
0 143 posted 12 years ago by thecrumb
Get a list of all the user tables.
0 120 posted 12 years ago by thecrumb
Get all my columns and comments.
0 89 posted 12 years ago by thecrumb
Noob stuff, but I always end up looking this up.
0 82 posted 12 years ago by rengber
Small query to help you relocate those modules you are not using anyways.
2 105 posted 12 years ago by torkil
1 130 posted 12 years ago by Abe
If you are deleting all the rows in a table and you also want to reset the values that will get used by auto increment, this is how to do it.
0 120 posted 12 years ago by jachin
You can generate a simple bar chart of the values by executing this command...
0 101 posted 12 years ago by zingo
0 74 posted 12 years ago by rengber
1 93 posted 13 years ago by Shpigford
This will return the number of seconds between now and when the time field was inserted.
0 129 posted 13 years ago by wolfie
7 127 posted 13 years ago by brentroady
Esta consulta nos permite comprobar si los registros obtenidos por dos consultas o vistas que operan de diferente forma son los mismos en ambos casos. Conviene adaptar las partes de la consulta de manera que se obtengan los resultados de nuestras dos...
0 84 posted 14 years ago by jomaweb
Example usage: exec sp_easypaging '[tblmessages]','[tblmessages].recid','','*','1 = 1','recid',1,5
0 106 posted 14 years ago by planetthoughtful
1 ... 8 9 10 11 12 Next »