Tricky SQL

Results 1 to 2 of 2

Thread: Tricky SQL

  1. #1
    Join Date
    Dec 1969

    Default Tricky SQL

    does anyone know how to update a number in a database by decreasing or increasing the current number in the database by the amount calculated in a script? i need to use an "update" statement, but not sure how to or if you even can. thnx.

  2. #2
    Join Date
    Dec 1969

    Default RE: Tricky SQL

    You should just be able to do something like this:<BR><BR>&#039establish a connection to your database using the variable myConn<BR>strSQL = "UPDATE myTable SET myNum = myNum + " & newValue<BR>myConn.Execute(strSQL)<BR><BR>Unless I&#039m misunderstanding you, I think it should be that simple.<BR><BR>Todd<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts