Suntower
Posts: 225
|
Posted: 08/18/2006, 4:50 PM |
|
Two things...
1. I thought I could simply put my own SQL Update statement into the BeforeExecuteUpdate event, but that doesn't seem to work.
2. So... How does one use the Custom Update Type (set to 'SQL') to do the following
"UPDATE CostCenters SET LASTREVISIONDATE = CAST(" & MYFORM.LASTREVISIONDATE.Value & " AS INT)"
I can't figure out how to use the Field and Parameters to get this to work. Anyone got an example?
Thanks!
---JC
_________________
---On a campaign for more examples and better docs! |
|
|
DonB
|
Posted: 08/19/2006, 3:33 PM |
|
In the SQL statement, you insert parameters in a WHERE clause like this:
{parameter1} (you would enclose this in apostrophes if it's a non-numeric
parameter)
In the SQL parameters, you add parameters with those same names, and
establish the datatype and tell CCS where the value.comes from.
--
DonB
http://www.gotodon.com/ccbth
"Suntower" <Suntower@forum.codecharge> wrote in message
news:444e6526401f3e@news.codecharge.com...
> Two things...
>
> 1. I thought I could simply put my own SQL Update statement into the
> BeforeExecuteUpdate event, but that doesn't seem to work.
>
> 2. So... How does one use the Custom Update Type (set to 'SQL') to do the
> following
>
> "UPDATE CostCenters SET LASTREVISIONDATE = CAST(" &
> MYFORM.LASTREVISIONDATE.Value & " AS INT)"
>
> I can't figure out how to use the Field and Parameters to get this to
work.
> Anyone got an example?
>
> Thanks!
>
> ---JC
> ---------------------------------------
> Sent from YesSoftware forum
> http://forums.codecharge.com/
>
|
|
|
|