Re: 0x800a0cb3 when Update record

Tech-Archive recommends: Fix windows errors by optimizing your registry



On Fri, 17 Oct 2008 08:36:52 -0400, Bob Barrows [MVP] wrote:

Anders Eriksson wrote:
On Thu, 16 Oct 2008 13:00:50 -0400, Bob Barrows [MVP] wrote:

If I change CursorLocation=asUseClient
I allways get CursorType=adOpenStatic and
LockType=adLockBatchOptimistic

What the ?

The latter result is expected. The only cursor type allowed with client-side
cursors is static. No matter what you request, you get static. The reason
for this is simple: with client-side cursors, the ADO cursor library handles
all cursor functionality. That means, it has to have all the data. So when a
client-side cursor is requested, ADO constructs a client-side cursor from
its library, and uses a server-side firehose cursor to populate it, closing
the server-side cursor when all the data has been sent. So, the client-side
cursor contains all the data that satisfies the sql statement and it cannot
respond to changes/deletions in the source data. This is the definition of a
static cursor. Also, since it has no direct connection to the underlying
data, it cannot apply a pessimistic lock.

Aha, I have learnt something new today!


As to ADO transactions not working with client-side cursors, I
believe the only case where this is true is with RDS, which you are
not using.

Aha, You need to read the header also ;-)

Why?


I missed the header that says Remote Data Service and I tried to be
funny, which obviously didn't work...

No, it worked (I smiled), but I was being subtle in return, which didn't
work.
Now, it just swoshed over my head ;-) See the signature...

I guess I'm wondering why you are using this obsolete technology in a
C++ application. Typically that technology was used in client-server
scenarios such as ASP, where the client portion of the app had no direct
connection to the server portion. Is that what you are building here?

No, I building an unmanaged C++ application. I'm guessing that the
non-obsolete technology is ADO.NET, but since I don't want to use .NET I'm
stuck with ADO...


Thanks for the URLs about programming Stored Procedures. I have (which is
uncommon) realized my short commings and since the customer has a database
department I will ask if they will create the Stored Procedure for me.

Thanks for all your help!

// Anders
--
English is not my first, or second, language
so anything strange, or insulting, is due to
the translation.
Please correct me so I may improve my English!
.



Relevant Pages