BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Occaisional bug in 7.08 IBDataset

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (InterBase Express)
View previous topic :: View next topic  
Author Message
Mark Horrocks
Guest





PostPosted: Thu May 10, 2007 7:08 pm    Post subject: Occaisional bug in 7.08 IBDataset Reply with quote



I use IBDataset for inserts. My SQL will typically be select * from MyTable
where aKeyField = 0

Sometimes, If I try to add fields using field editor after adding a new
table to the DB (Firebird 2.0) I get an SQL error "..token unknown line 2
column 1 from".

The SQL couldn't be simpler. If I use the field names in the SQL statement
instead of * I get the same error even when "from" is nowhere near line 2 .
The only thing that fixes the problem is to delete the IBDataset and replace
it with a new one.

Any ideas what causes this? I have double checked that the SQL is saved but
clearly something is not being updated or is corrupted.

Mark Horrocks
Back to top
Craig Stuntz [TeamB]
Guest





PostPosted: Thu May 10, 2007 10:21 pm    Post subject: Re: Occaisional bug in 7.08 IBDataset Reply with quote



IBX, AFAIK, never changes your SQL at all. You can use the
TIBSQLMonitor to see what the app is doing, but if you're getting bad
SQL it must be from your app.

--
Craig Stuntz [TeamB] ˇ Vertex Systems Corp. ˇ Columbus, OH
Delphi/InterBase Weblog : http://blogs.teamb.com/craigstuntz
Borland newsgroup denizen Sergio González has a new CD of
Irish music out, and it's good: http://tinyurl.com/7hgfr
Back to top
Francois Malan
Guest





PostPosted: Fri May 11, 2007 8:11 am    Post subject: Re: Occaisional bug in 7.08 IBDataset Reply with quote



Mark Horrocks wrote:

Quote:
I use IBDataset for inserts. My SQL will typically be select * from
MyTable where aKeyField = 0

Sometimes, If I try to add fields using field editor after adding a
new table to the DB (Firebird 2.0) I get an SQL error "..token
unknown line 2 column 1 from".

The SQL couldn't be simpler. If I use the field names in the SQL
statement instead of * I get the same error even when "from" is
nowhere near line 2 . The only thing that fixes the problem is to
delete the IBDataset and replace it with a new one.

Any ideas what causes this? I have double checked that the SQL is
saved but clearly something is not being updated or is corrupted.

Mark Horrocks

How do you add the fields?

If you do something like MyDataset.SQL.Add('SELECT a,b,c FROM mytable')
then of course you could end up with a problem, you should first clear
the existing SQl with MyDataSet.SQL.Clear; ... and the add your sql.

--
Back to top
ssamayoa
Guest





PostPosted: Sat May 12, 2007 2:52 am    Post subject: Re: Occaisional bug in 7.08 IBDataset Reply with quote

Quote:
Sometimes, If I try to add fields using field editor after adding a new
table to the DB (Firebird 2.0) I get an SQL error "..token unknown line 2
column 1 from".

I experienced similar problems but with "select" clause at run time. The
only solution is to edit the form / data module source, change anything
(hit space in empty line) and recompile then the error goes away.

Did you try disconnectiong / connection the database component?

Regards.



--- posted by geoForum on http://delphi.newswhat.com
Back to top
Mark Horrocks
Guest





PostPosted: Tue May 15, 2007 4:38 pm    Post subject: Re: Occaisional bug in 7.08 IBDataset Reply with quote

I am getting this error with SQL at design time, I am not changing the SQL
at run time. It happens with SQL as simple as select * from mytable where
pkfield = 0.

If I blank the SQL and replace it the problem remains, if I change the SQL
(at design time) to select field names instead of * the problem remains with
the original error message pointing to the original (now wrong) line.

Deleting the dataset and replacing it fixes the problem.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (InterBase Express) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.