Search Postgresql Archives

ISO something like "#if 0 ... #endif" for SQL code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 






Hi!  When it comes to programming SQL, my newbie approach is to write my code in a file test.sql, which I test from within psql by using

  my_db=> \i /some/path/test.sql

...and (once I'm satisfied with the code) copy and paste it to a different file that has the SQL I've written so far for the project.

It's a rather cumbersome system, all the more so because I don't have a convenient way to comment out large chunks of code (which may include C-style comments).

I'm thinking of something like the trick of surrounding C code with pairs of #if 0 and #endif, which effectively comments out code, even when it contains /* C-style comments */.

Is there some similar trick for SQL code?

TIA!

Kynn


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux