PC Review


Reply
Thread Tools Rate Thread

Bug in framework : variable stay unchanged ???

 
 
Ludovic Lemarinel
Guest
Posts: n/a
 
      3rd Oct 2003
Hi

I've been working on the dotnet framework in vb for a while (about One
year), and I've got a problem :

I've written a piece of code which makes a first recordset :

dim query, updtquery as string

query="SELECT fooo FROM fooo_table "
rs = cn.openrecordset(query)
while (not query.eof)
updtquery="UPDATE foo2_table SET foofield='some value' WHERE
foofield2='some value' "
'execute the updtquery
some code to run the updtquery
end while

And I've got a bunch of 10 to 20 loops like this one.

Since the 8-9th loop, the updtquery string does'nt vary anymore : I explain:
when I go throught updtquery="UPDATE foo2..., while debugging and executing
the updtquery, the variable value don't change ??? It stays at his old
value, and stays again while I try to change it for about 60 times !!!! (and
never changes !!!!!)

Is this a bug in the Dotnet Framework????

(Running under WinXP, SQL Server 7 on remote server)

Please heeelp me !?

thanks


 
Reply With Quote
 
 
 
 
a
Guest
Posts: n/a
 
      3rd Oct 2003
Put the real code, and we can see what it is doing / not doing. Is ther
something to increment the variable?
> while (not query.eof)

would need to be
rs.eof
because
query
is a string.



"Ludovic Lemarinel" <(E-Mail Removed)> wrote in message
news:bljf5u$pv0$(E-Mail Removed)...
> Hi
>
> I've been working on the dotnet framework in vb for a while (about One
> year), and I've got a problem :
>
> I've written a piece of code which makes a first recordset :
>
> dim query, updtquery as string
>
> query="SELECT fooo FROM fooo_table "
> rs = cn.openrecordset(query)
> while (not query.eof)
> updtquery="UPDATE foo2_table SET foofield='some value' WHERE
> foofield2='some value' "
> 'execute the updtquery
> some code to run the updtquery
> end while
>
> And I've got a bunch of 10 to 20 loops like this one.
>
> Since the 8-9th loop, the updtquery string does'nt vary anymore : I

explain:
> when I go throught updtquery="UPDATE foo2..., while debugging and

executing
> the updtquery, the variable value don't change ??? It stays at his old
> value, and stays again while I try to change it for about 60 times !!!!

(and
> never changes !!!!!)
>
> Is this a bug in the Dotnet Framework????
>
> (Running under WinXP, SQL Server 7 on remote server)
>
> Please heeelp me !?
>
> thanks
>
>



 
Reply With Quote
 
Jerry
Guest
Posts: n/a
 
      3rd Oct 2003
"openrecordset" ???
Is this VB6?
We use datasets here.

"Ludovic Lemarinel" <(E-Mail Removed)> wrote in message
news:bljf5u$pv0$(E-Mail Removed)...
> Hi
>
> I've been working on the dotnet framework in vb for a while (about One
> year), and I've got a problem :
>
> I've written a piece of code which makes a first recordset :
>
> dim query, updtquery as string
>
> query="SELECT fooo FROM fooo_table "
> rs = cn.openrecordset(query)
> while (not query.eof)
> updtquery="UPDATE foo2_table SET foofield='some value' WHERE
> foofield2='some value' "
> 'execute the updtquery
> some code to run the updtquery
> end while
>
> And I've got a bunch of 10 to 20 loops like this one.
>
> Since the 8-9th loop, the updtquery string does'nt vary anymore : I

explain:
> when I go throught updtquery="UPDATE foo2..., while debugging and

executing
> the updtquery, the variable value don't change ??? It stays at his old
> value, and stays again while I try to change it for about 60 times !!!!

(and
> never changes !!!!!)
>
> Is this a bug in the Dotnet Framework????
>
> (Running under WinXP, SQL Server 7 on remote server)
>
> Please heeelp me !?
>
> thanks
>
>



 
Reply With Quote
 
Armin Zingler
Guest
Posts: n/a
 
      3rd Oct 2003
"Jerry" <(E-Mail Removed)> schrieb
> "openrecordset" ???
> Is this VB6?


No

> We use datasets here.


We? Who is we? I don't use datasets here. ;-)


--
Armin

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I order by a variable column name in entity framework? Ilyas Microsoft C# .NET 0 20th Nov 2008 08:32 AM
How to get the unchanged row of a changed row - ado.net 2.0 Rolf Welskes Microsoft ADO .NET 4 2nd Mar 2007 12:16 PM
How long will it stay beta/howlong will it stay free? Yukk Spyware Announcements 3 9th Jan 2005 02:34 AM
how do you stay with VS.NET(not 2003) and still use 1.1 Framework? Ken Microsoft Dot NET Framework Forms 1 5th Sep 2003 01:38 PM
simple TCP socket connect (emulator - framework FAIL); framework - framework - Works [Help will be compensated] Yechezkal Gutfreund Microsoft Dot NET Compact Framework 0 16th Jul 2003 06:28 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:08 AM.