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!

Fieldnames with minus sign in SQl statement

Status
Not open for further replies.

BasSchouten

IS-IT--Management
Jul 31, 2001
33
NL
I have a table with field names containing minus-signs like
Code:
art-fabr

if i try to use these fieldnames in a SQL-statement of a TAdsQuery object it sees the minus sign as a minus sign and tell me it can't find the field "art"

does anybody know a way to avoid this??
(by the way: renaming the fields is not an option) Bas Schouten
System Development & Webdesign
CBIS BV Holland
logo.gif

 
well, I thought I had tried any logical characters like single quote, double quote, back quote, brackets, parentheses and any combination of them ... but it didnt work.

Then suddenly the double quotes seeemed to work!!!

So I guess I have doen something wrong, but the solution is using double quotes:

Code:
table."field-name"
Bas Schouten
System Development & Webdesign
CBIS BV Holland
logo.gif

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top