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 

TSQLQuery D2006 vs D7

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (dbExpress)
View previous topic :: View next topic  
Author Message
Ronny Bengtsson
Guest





PostPosted: Mon Feb 27, 2006 3:03 pm    Post subject: TSQLQuery D2006 vs D7 Reply with quote



Hi,

D2006 update1
IB 7.5.1
DBExpress

I have just migrated from D7 to D2006 and fiķund that the TSQLQuery
don't behave as in D7.
I get an AccessViolation when I try to use FIELDS[] value when the query
doesn't gives any results back, However this was working in D7. Are
there any settings I can do or do I need to change all these lines in my
code?

with TSQLQuery.Create(self) do
try
SQLConnection := MainDM.SQLConnectionSaSiMS1;
SQL.Add('SELECT field1, field2');
SQL.Add('FROM table1');
SQL.Add('WHERE field_x = 2');
SQL.Add('AND field_y = 1200');
Open;
if Fields[1].AsString <> '' then <---- Access Violation
begin
...........
end;
finally
Free;
end;


/Ronny
Back to top
Justin Swett
Guest





PostPosted: Tue Feb 28, 2006 1:03 am    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote



Hi Ronny,

This issue will be addressed in Update2.

Cheers,
Justin

Ronny Bengtsson wrote:

Quote:
Hi,

D2006 update1
IB 7.5.1
DBExpress

I have just migrated from D7 to D2006 and fisund that the TSQLQuery
don't behave as in D7.
I get an AccessViolation when I try to use FIELDS[] value when the
query doesn't gives any results back, However this was working in D7.
Are there any settings I can do or do I need to change all these
lines in my code?

with TSQLQuery.Create(self) do
try
SQLConnection := MainDM.SQLConnectionSaSiMS1;
SQL.Add('SELECT field1, field2');
SQL.Add('FROM table1');
SQL.Add('WHERE field_x = 2');
SQL.Add('AND field_y = 1200');
Open;
if Fields[1].AsString <> '' then <---- Access Violation
begin
...........
end;
finally
Free;
end;


/Ronny



--
Back to top
Ronny Bengtsson
Guest





PostPosted: Tue Feb 28, 2006 10:03 am    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote



Justin,


Thanks, any timeline for update 2?

/Ronny
Back to top
Ronny Bengtsson
Guest





PostPosted: Wed Mar 01, 2006 10:03 pm    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote

All,

Well, as I haven't got an accurate reply to my previous reply re this and
I'm sort of pissed off (excuse my language), but to whom should I point my
anger to?

I have paid a quit of a figure of my expected benefit to Borland and it's
related companies due to my upgrade.
I expect a more accurate and in time answer to the extended work I need to
do to accomplish/hide the current bugs against my customers due the to
upgrade to D2006.

Anyone!

/Ronny
Back to top
Dan Miser
Guest





PostPosted: Thu Mar 02, 2006 4:03 am    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote

You did get a reply. It will be fixed in Update 2. The timeline for update 2
is "soon". Borland has never given a date and time for this.

Lastly, you can easily work around this issue. After Open, check if IsEmpty
before evaluating your Field.AsString properties.
--
Dan Miser
http://www.distribucon.com

"Ronny Bengtsson" <Ronny_Bengtsson (AT) hotmail (DOT) com> wrote in message
news:Xns9779E55027823ronnybengtssonrobese (AT) 207 (DOT) 105.83.66...
Quote:
All,

Well, as I haven't got an accurate reply to my previous reply re this and
I'm sort of pissed off (excuse my language), but to whom should I point my
anger to?

I have paid a quit of a figure of my expected benefit to Borland and it's
related companies due to my upgrade.
I expect a more accurate and in time answer to the extended work I need to
do to accomplish/hide the current bugs against my customers due the to
upgrade to D2006.

Anyone!
Back to top
Ronny Bengtsson
Guest





PostPosted: Thu Mar 02, 2006 7:03 am    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote

Dan,

Thanks.
Yea, I know I got the answer re the update 2 but it's still
frustrating that this is a too obvious bug that has "slipped" trough the
D2006 testing (if any) and I don't like to go trough all my code and do
changes to be able to use a tool (D2006) which I supposed be working at
least as the previous version. I haven't been surprised if new features
didn't work as expected.

Anyhow a big thanks to all of you that spend your free time to answer
queries on this forum and my anger is directed to Borland as a
company not to any individual.

/Ronny
Back to top
Erick Sasse
Guest





PostPosted: Sat Mar 04, 2006 9:03 pm    Post subject: Re: TSQLQuery D2006 vs D7 Reply with quote

Ronny Bengtsson wrote:

Quote:
Yea, I know I got the answer re the update 2 but it's still
frustrating that this is a too obvious bug that has "slipped" trough
the D2006 testing (if any) and I don't like to go trough all my code
and do changes to be able to use a tool (D2006) which I supposed be
working at least as the previous version.

I agree with you and we all hope this kind of problems ends with the
new DevCo.

--
Erick Sasse
Brazil
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (dbExpress) 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.