Buy Support
Incidents |
If you can't find your answer
in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us
private or confidential information: |
Click Here
|
If you can't
login and post questions or you are having trouble viewing forum posts:
Click Here
|
Callback
Support |
If you live in USA, UK, Canada, Australia or New
Zealand, you can leave us details on your question and request us to call you back and discuss
them with you personally (charges apply). |
Click Here
|
Buy Support
Incidents |
If you can't find your answer
in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us
private or confidential information: |
Click Here
|
|
I am having problems with the Desc field in the Account table using a select statement? |
Author |
Message |
Tom |
|
Group | : Administrator |
Posts | : 5510 |
Joined | : 2006-02-17 |
|
Profile |
|
Posted : 2006-04-13 08:41:26 |
I am having problems with the Desc field in the Account table using a select statement.
This Fails:
SELECT ListID, TimeCreated, TimeModified, Name, IsActive, ParentRefListID, ParentRefFullName, Sublevel, AccountType, AccountNumber, BankNumber, Desc, Balance From Account Where IsActive = 1
While this Works:
SELECT ListID, TimeCreated, TimeModified, Name, IsActive, ParentRefListID, ParentRefFullName, Sublevel, AccountType, AccountNumber, BankNumber, Balance From Account Where IsActive = 1
If I attempt to access anything in the recordset I receive:
Err 3704 Error: Operation is not allowed when the object is closed. |
|
|
|
Tom |
|
Group | : Administrator |
Posts | : 5510 |
Joined | : 2006-02-17 |
|
Profile |
|
Posted : 2006-04-13 08:47:18 |
The problem here is that DESC is the reserved SQL word for DESCENDING. So what you need to do is to place double quotes around any "DESC" column used in QODBC like this:
SELECT ListID, TimeCreated, TimeModified, Name, IsActive, ParentRefListID, ParentRefFullName, Sublevel, AccountType, AccountNumber, BankNumber, "Desc", Balance From Account Where IsActive = 1
|
|
|
|
|