Tally List : mailing list management, archiving, and analysis
click for archive home
 
Archive of:
CF-Server
Cold Fusion Server Tech
 
home
24 hour view
quick stats
weekly updates
 
all tallylists
corporate solutions
archive your favorite
help / feedback


Search the Tallylist search by keyword:

About Cold Fusion :
product's home
product's list home
 
  Archived TallyList / CF-Server: 
Subject: Re: error insert date to sybase DB
Tariq Ahmed (14p/+0r)     Posted: Tuesday 02 Jan 2001
This post: 101 views, +0 rating

I think you might have to specify the column names:

<CFQUERY name="Additem" datasource="Database"> INSERT INTO proitem (field1, field2, field3) VALUES '#itemid#', #form.costprice#, '#DateFormat(CreateDate(form.year, form.month, form.day),"dd-mm-yyyy")#') </CFQUERY>

Sybase needs single quotes around the date and string fields.

On Tue, 2 Jan 2001, Mak Wing Lok wrote:

> i encountered an error when i try to insert a date into sybase db table. > the sql statement > > <cfquery name="additem" datasource="database"> > > insert into proitem values("#itemid#", #form.costprice#, > #DateFormat(CreateDate(form.year, form.month, form.day),"dd-mm-yyyy")#) > </cfquery> > > it give me an error from sybase side, then i try to substitute the whole > DateFormat function with a variable but it still have the same error > nyone know what seems to be the problem.? > > regards > > > > ~~~~~~~~~~~~~ Paid Sponsorship ~~~~~~~~~~~~~ Get Your Own Dedicated Win2K Server! Instant Activation for $99/month w/Free Setup from SoloServer PIII600 / 128 MB RAM / 20 GB HD / 24/7/365 Tech Support Visit SoloServer, https://secure.irides.com/clientsetup.cfm. ------------------------------------------------------------------------------ To unsubscribe, send a message to cf-server-request@houseoffusion.com with 'unsubscribe' in the body or visit the list page at www.houseoffusion.com


Similar Subject Line Posts (+/- two weeks of this post)
Re: error insert date to sybase DB  02 Jan 2001 (this post)   (101 v/ +0 r)
Re: error insert date to sybase DB  02 Jan 2001   (85 v/ +0 r)
Re: error insert date to sybase DB  02 Jan 2001   (84 v/ +0 r)
RE: error insert date to sybase DB  02 Jan 2001   (95 v/ +0 r)
Re: error insert date to sybase DB  02 Jan 2001   (90 v/ +0 r)
Re: error insert date to sybase DB  02 Jan 2001   (110 v/ +0 r)
error insert date to sybase DB  02 Jan 2001   (127 v/ +0 r)
 

Send a reply to the CF-Server list!
click to send a reply! NOTE: Many lists will reject your post unless you have already registered with them. Also - don't forget the right account to send from (for those with multiple emails!)

Feedback: If this post was exceptionally helpful, please help by giving this post a positive review.

 

TallyList : copyright Ububik - 2000