SqlDbx
You are not logged in.
Pages: 1
is there anyway i can write comments in a DB2 script?
DB2 spufi allows you to write comments on sequel codes. Is there anything similar in SqlDbx?
Offline
I am not sure I understand what you mean.
Can you provide example.
Offline
DB2 Spufi requires a double-dash, "--", on the first two positions of a statement line for it to be treated as a comment. An example is:
select *
-- from tableA
from tableB
with ur;
the statement that has the double-dash on the first two position will not be executed and will be ignored as a comment line.
SQLDbx, apparently does not have this feature. Or, does it?
Offline
I assume you are connecting to DB2 on z/OS
Before version 9 DB2 had issue with '--' style comments,
so tools like SPUFI were removing them before sending statement to server.
/* */ style comment does work.
For example following statement works ok:
select *
/* from tableA */
from tableB -- rest is a comment
with UR
Currently SqlDbx does not try to emulate SPUFI behavior
Offline
Thank you. this helps me.. In my machine SQLDBX not recoginze '--' as comment inside SQL -
It's identifying /* ....... */
Example -
select * from A
--Fetch first 10 rows only
fetch first 20 rows only;
above sql returning all the rows in side A table
but if i use follwoing sql - its fetching only 20 rows..
select * from A
/* Fetch first 10 rows only */
fetch first 20 rows only;
dont now the reason.. but its working...
Thanks
Vasu
Offline
Pages: 1