|
 |
asp_databases thread: Error 80040E21 - Why??
Message #1 by "Thomas Gigge" <tg2@t...> on Thu, 26 Jul 2001 18:29:49
|
|
Hi,
I can not tell you the english error message, because I see it only in germany. The error
number is 80040E21. Please look on this example:
Set RS = CreateObject("ADODB.Recordset")
sql = "SELECT * FROM pincode WHERE PinCode='036523'"
adCmdText=1
adOpenDynamic=2
adLockOptimistic=3
RS.Open sql,"DSN=test1",adOpenDynamic,adLockOptimistic,adCmdText
If Not RS.EOF Then
With RS
str = .Fields("field1")
str = str & "*"
.Fields("field1") = str <**>
.Update
End With
End If
RS.Close
The error occurs in the line marked with "<**>", because I used the same fields two lines
before. Is it not allowed to read und chance a field-value in one step ?
I have tested this on 3 PCs with: WSCRIPT test.vbs
Can anybody help me?
Thomas.
Message #2 by "Grant I" <giswim1@a...> on Thu, 26 Jul 2001 20:14:02
|
|
Meine deutsch ist nicht sehr gut, aber ich versuche...
Ja... Sie konnen in eine Operation lesen und schreiben. Hat Ihre
Datenbank, Erlaubnis zu schreiben? (Das ist auf dem Server) Wenn ja,
weiB ich nicht. Aber wenn nein, dieses konnte Ihr Problem sein.
HTH
Grant
> Hi,
>
> I can not tell you the english error message, because I see it only in
germany. The error
> number is 80040E21. Please look on this example:
>
> Set RS = CreateObject("ADODB.Recordset")
>
> sql = "SELECT * FROM pincode WHERE PinCode='036523'"
>
> adCmdText=1
> adOpenDynamic=2
> adLockOptimistic=3
>
> RS.Open sql,"DSN=test1",adOpenDynamic,adLockOptimistic,adCmdText
>
> If Not RS.EOF Then
> With RS
> str = .Fields("field1")
> str = str & "*"
>
> .Fields("field1") = str <**>
> .Update
> End With
> End If
>
> RS.Close
>
>
> The error occurs in the line marked with "<**>", because I used the same
fields two lines
> before. Is it not allowed to read und chance a field-value in one step ?
>
> I have tested this on 3 PCs with: WSCRIPT test.vbs
>
> Can anybody help me?
>
> Thomas.
Message #3 by Thomas Gigge <tg2@t...> on Fri, 27 Jul 2001 00:07:26 +0200
|
|
Grant I wrote:
> Meine deutsch ist nicht sehr gut, aber ich versuche...
>
> Ja... Sie konnen in eine Operation lesen und schreiben. Hat Ihre
> Datenbank, Erlaubnis zu schreiben? (Das ist auf dem Server) Wenn ja,
> weiB ich nicht. Aber wenn nein, dieses konnte Ihr Problem sein.
>
> HTH
> Grant
Hallo, die Datenbank hat Schreibrechte. Übrigens ist Ihr Deutsch sehr gut!
Thomas.
Message #4 by "Ken Schaefer" <ken@a...> on Fri, 27 Jul 2001 10:16:35 +1000
|
|
http://www.adopenstatic.com/faq/80040e21.asp
6 causes and solutions for 80040e21 errors.
Cheers
Ken
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
----- Original Message -----
From: "Grant I" <giswim1@a...>
To: "ASP Databases" <asp_databases@p...>
Sent: Thursday, July 26, 2001 8:14 PM
Subject: [asp_databases] Re: Error 80040E21 - Why??
: Meine deutsch ist nicht sehr gut, aber ich versuche...
:
: Ja... Sie konnen in eine Operation lesen und schreiben. Hat Ihre
: Datenbank, Erlaubnis zu schreiben? (Das ist auf dem Server) Wenn ja,
: weiB ich nicht. Aber wenn nein, dieses konnte Ihr Problem sein.
:
: HTH
: Grant
:
: > Hi,
: >
: > I can not tell you the english error message, because I see it only in
: germany. The error
: > number is 80040E21. Please look on this example:
: >
: > Set RS = CreateObject("ADODB.Recordset")
: >
: > sql = "SELECT * FROM pincode WHERE PinCode='036523'"
: >
: > adCmdText=1
: > adOpenDynamic=2
: > adLockOptimistic=3
: >
: > RS.Open sql,"DSN=test1",adOpenDynamic,adLockOptimistic,adCmdText
: >
: > If Not RS.EOF Then
: > With RS
: > str = .Fields("field1")
: > str = str & "*"
: >
: > .Fields("field1") = str <**>
: > .Update
: > End With
: > End If
: >
: > RS.Close
: >
: >
: > The error occurs in the line marked with "<**>", because I used the same
: fields two lines
: > before. Is it not allowed to read und chance a field-value in one step ?
Message #5 by Steve Carter <Steve.Carter@t...> on Fri, 27 Jul 2001 10:19:07 +0100
|
|
Ja, das is what I was going to sprach. :-)
Especially if that was all about having write permissions to the
database file (Access) or database table (SQLServer)
Tchus
Steve
> -----Original Message-----
> From: Grant I [mailto:giswim1@a...]
> Sent: 26 July 2001 21:14
> To: ASP Databases
> Subject: [asp_databases] Re: Error 80040E21 - Why??
>
>
> Meine deutsch ist nicht sehr gut, aber ich versuche...
>
> Ja... Sie konnen in eine Operation lesen und schreiben. Hat Ihre
> Datenbank, Erlaubnis zu schreiben? (Das ist auf dem Server)
> Wenn ja,
> weiB ich nicht. Aber wenn nein, dieses konnte Ihr Problem sein.
>
> HTH
> Grant
|
|
 |