Current Date value - Command Sstring

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have the following command string but would like to replace the 'manually'
entered date with an automated current date value - can anyone help?

EXEC vpmser.dbo.rep_AgedDebt N'20070320'
 
Create a variable to hold the date, ex: datevariable, and then pass it to
the Stored Procedure. Ex:

SQL = "EXEC vpmser.dbo.rep_AgedDebt @N= '" & datevaiable & "' "

OR

SQL = "EXEC vpmser.dbo.rep_AgedDebt = " ' " & datevaiable & " ' "
 
Hi David,

Thanks very much for the assistance. I am not sure how to go about this,
are you able to assist further?
 
Where are you using this code? If you switch to Code View you can change
the line there? Without seeing all the code for your page it's hard to tell
what needs to be changed. To declare a variable you'd put

dim datevariable
datevariable = ............

the part after the = depends on where the database is coming from (a form, a
querystring, a database etc ..)
 
Back
Top