Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Help With Code
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Help With Code

 Post Reply Post Reply Page  <123>
Author
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 07 January 2005 at 3:55pm
the full query needs to be


sql = "SELECT tblUsers.* FROM tblUsers WHERE tblUsers.User_ID = " & UserID

Back to Top
felix.akinyemi View Drop Down
Groupie
Groupie
Avatar

Joined: 09 December 2004
Location: United States
Status: Offline
Points: 113
Post Options Post Options   Thanks (0) Thanks(0)   Quote felix.akinyemi Quote  Post ReplyReply Direct Link To This Post Posted: 07 January 2005 at 4:27pm
thanks, that got it workin!!! Smile

Edited by felix.akinyemi - 07 January 2005 at 4:28pm
Back to Top
felix.akinyemi View Drop Down
Groupie
Groupie
Avatar

Joined: 09 December 2004
Location: United States
Status: Offline
Points: 113
Post Options Post Options   Thanks (0) Thanks(0)   Quote felix.akinyemi Quote  Post ReplyReply Direct Link To This Post Posted: 07 January 2005 at 5:08pm
Originally posted by dj air dj air wrote:

the full query needs to be


sql = "SELECT tblUsers.* FROM tblUsers WHERE tblUsers.User_ID = " & UserID

 
i used this query to update but im gettin an error...
 

ADODB.Recordset error '800a0cb3'

Current Recordset does not support updating. This may be a limitation of the provider, or of the selected locktype.

 
and the code on line is
 
e.g.

rs.fields("name") = name
 
do i have to change the query


Edited by felix.akinyemi - 07 January 2005 at 5:10pm
Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 07 January 2005 at 7:03pm
before rs.open


i think you need

rs.cursortype = 3

then it will be ok.
Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 08 January 2005 at 6:54am
sorry, at 1 thismorning, i releaised i posting the wrong code its

rs.locktype = 3

not the above one.

iots one of those cases we where tallking about (realise after the computer is turned off).
Back to Top
felix.akinyemi View Drop Down
Groupie
Groupie
Avatar

Joined: 09 December 2004
Location: United States
Status: Offline
Points: 113
Post Options Post Options   Thanks (0) Thanks(0)   Quote felix.akinyemi Quote  Post ReplyReply Direct Link To This Post Posted: 08 January 2005 at 8:11am
LoL... i no what u mean...
 
rs.locktype = 3
 
that got it workin, thanks... but can u pls explain what it means and what it does!!! Confused
Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 08 January 2005 at 2:55pm
the record is not locked unless its being updated.

i believe thats what it does. by default its set to not allow it,
Back to Top
felix.akinyemi View Drop Down
Groupie
Groupie
Avatar

Joined: 09 December 2004
Location: United States
Status: Offline
Points: 113
Post Options Post Options   Thanks (0) Thanks(0)   Quote felix.akinyemi Quote  Post ReplyReply Direct Link To This Post Posted: 08 January 2005 at 3:39pm
one more problem, im tryin so make it so that it checks if the username already exsist in the database im usin this, but its not workin...
 
 

 Set rs = Server.CreateObject("ADODB.Recordset")
 sql = "SELECT * FROM tblUsers"
 rs.Open sql, OBJdbConnection
 Do While Not rs.EOF
  If rs.fields("UserID") <> Username Then
   rs.movenext
  Else
   Response.Redirect("errorpage.asp?code=1")
  End If
 Loop
 
lil help!!
Back to Top
 Post Reply Post Reply Page  <123>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.