Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VC++ SQL error......

Status
Not open for further replies.

noaaprogrammer

Programmer
May 4, 2001
36
US
I am getting an "Invalid descriptor index" error when I run the following query in VC++.

select translate(raw_message, chr(0), chr(7))raw_message from raw_data where payload_message_id='46069' and measurement_date=to_date('2004050315','YYYYMMDDHH24')

This query runs just fine in SQL Plus. Does VC++ not support the translate() function?
 
And this query runs fine in VC++:

select * from raw_data where payload_message_id='46069' and measurement_date=to_date('2004050315','YYYYMMDDHH24')
 
VC++ doess not supporrt any SQL functions

Ion Filipski
1c.bmp
 
I figured it out. When I created the database class using the '*', VC++ created objects for all of the columns. In my query that only selected one of those columns, VC++ couldn't find the data to fill all of the database objects, so the error was a result. I added all of the columns to my query, and it works fine now.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top