Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

IB Database Connection Fails in Delphi 8

4 views
Skip to first unread message

Chad McBride

unread,
May 11, 2004, 5:43:09 PM5/11/04
to

I created a simple IB DB from IB Console, with the fields shown below. I set the ID as the primary field. When I connect to the database from BDE Administrator, it connects fine. So I then created a simple VCL forms application in Delphi 8 and I followed the instructions for connecting to a database. I then connect it to a DBGrid component and it seems to find the field names fine, but it then gives me the following error.

General SQL error.
Token unknown - line1, char 17
Level.

Anyone have any ideas on how to fix this?


ID INTEGER PRIMARY KEY
NAME CHAR(20)
LEVEL INTEGER
SOURCE INTEGER
DESTINATION INTEGER

Craig Stuntz [TeamB]

unread,
May 11, 2004, 6:00:37 PM5/11/04
to
Chad McBride wrote:

> Anyone have any ideas on how to fix this?

The error message suggests that you have bad SQL.

But since this does not appear to be an InterBase bug, it's off-topic
here. I'd suggest posting more information to either interbase.general
or, better still, one of the delphi.database groups.

-Craig

--
Craig Stuntz [TeamB] . Vertex Systems Corp. . Columbus, OH
Delphi/InterBase Weblog : http://delphi.weblogs.com
InterBase 7 supports long-running transactions; read more here:
http://delphi.weblogs.com/stories/storyReader$379

Charlie Caro

unread,
May 11, 2004, 6:10:57 PM5/11/04
to
LEVEL is a reserved SQL keyword (as in transaction ISOLATION LEVEL). You
will have change the name of that column.

quinn wildman

unread,
May 11, 2004, 6:30:04 PM5/11/04
to
Or put " around it. Make sure you inform your driver, BDE or otherwise,
that you are using dialect 3.

Jeff Overcash (TeamB)

unread,
May 12, 2004, 5:14:05 PM5/12/04
to
Charlie Caro <cc...@borland.com> wrote:
>LEVEL is a reserved SQL keyword (as in transaction ISOLATION LEVEL). You
>will have change the name of that column.
>

Or use quoted identifiers when accessing it (simpler to not user
keywords though).

0 new messages