If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > issue with esql code

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-08-09, 08:18
SmithaIVR SmithaIVR is offline
Registered User
 
Join Date: Dec 2008
Posts: 4
Question issue with esql code

Hi,

Has anybody used a declaration like:
$include sqlca ;
...
$char dbname[50];

I would like to know this kind of usage with $ in the begining is used for which version of esql/informix. I am using informix database.
This particular code was in my .ec file. I have normally seen #include <sqlca.h>.

To further understand the code I would like to know what is the informix/esql used here.

Thanks,
Smitha
Reply With Quote
  #2 (permalink)  
Old 01-10-09, 06:41
stanislav.ondac stanislav.ondac is offline
Registered User
 
Join Date: Aug 2005
Posts: 140
The $ usage is equivalent to
'EXEC SQL include filename'

Use ESQL/C include directive(with $) if the file you specify contains embedded SQL statements, or other ESQL/C statements.

Use standard C #include directive to include system header files.

The difference is that the '#include', includes a file after ESQL/C preprocessing in opposite to the first way(esql/c include) where the ESQL/C preprocessor places the contents of the specified file into the ESQL/C source file .
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On