if i open a connection and then open a datareader off that
connection.

then loop through the datareader attempting to perform
updates through the same connection, then i get an error

"There is already an open DataReader associated with this
Connection which must be closed first."

oh and the there is a transaction based on the connection.

should i maybe use a dataset ?

dan

Re: sqlConnection by Miha

Miha
Fri Dec 05 11:45:42 CST 2003

Hi dan,

Only one operation per connection can be done at same time.
Thus, if you are using reader to perform some operation, you will need
another connection instance to perform other tasks.

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

"dan182" <danielmclaglen@headstartsoftware.co.uk> wrote in message
news:06b701c3bb52$d116ca70$a001280a@phx.gbl...
> if i open a connection and then open a datareader off that
> connection.
>
> then loop through the datareader attempting to perform
> updates through the same connection, then i get an error
>
> "There is already an open DataReader associated with this
> Connection which must be closed first."
>
> oh and the there is a transaction based on the connection.
>
> should i maybe use a dataset ?
>
> dan