Solved

Table column name conflicts with keyword "date"...

Posted on 2004-08-30
5
356 Views
Last Modified: 2012-06-27
Hi!
    I am using CTLib to connect the Sybase IQ database. There is a table named "Table1" and one column named "date".

The following is the SQL:
   select "date" from "Table1"

This statement works in the interactive SQL environment but FAIL in CTLib API.


Could somebody help? thanks.
0
Comment
Question by:small_potato
  • 2
  • 2
5 Comments
 
LVL 6

Expert Comment

by:ChrisKing
ID: 11939934
What CT-Lib command are you using to execute this ?
0
 

Author Comment

by:small_potato
ID: 11940334
The sequence is:
ct_command()
ct_send()
ct_result()

The return result is FAIL.
0
 
LVL 6

Expert Comment

by:ChrisKing
ID: 11941027
I have no issue embedding quotes, are you using CS_LANG_CMD and CS_NULLTERM ?
eg. ct_command(..., CS_LANG_CMD, (CS_VOID *) QueryString, CS_NULLTERM, CS_UNUSED)

can you provide the actual line of c code where you set / pass you query string
0
 
LVL 19

Accepted Solution

by:
grant300 earned 250 total points
ID: 11947741
Try using the command:
    set quoted identifiers on

If that doesn't work, try setting them off.

I believe there is a different default setting for the connection depending on whether you are using jConnect 5.5 or isql/ct_lib directly.  You can try setting them on and off in ISQL as well and see what happens.

Bill
0
 

Author Comment

by:small_potato
ID: 11970594
Thank you very much!
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Is your phone running out of space to hold pictures?  This article will show you quick tips on how to solve this problem.
ConnectWise and their customers need to ensure critical alerts automatically reach the right person at the right time. MSP superheros efficiently respond to these alerts key is providing automatic, intelligent alerting that generates a complete audi…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question