This also gave me the REXX error.
<cfquery name="NewCase" datasource="lsar_prod">
insert into lsar.submissions (lid, assignedto, constituent, doc_date,
dead_date, subtype, subject, subjdetail, received, tone, enteredby,
date_assigned, date_closed, addressedto, documents, draft, assignedby,
completed)
values ('#form.lid#', '#form.assignedto#', '#form.constituent#',
#CreateODBCDate(PreserveSingleQuotes(form.doc_date))#,
#CreateODBCDate(PreserveSingleQuotes(form.dead_date))#,
'#form.subtype#', '#form.subject#', '#form.subjdetail#',
'#form.received#', '#form.tone#', 'Sandy Crisafulli',
#CreateODBCDate(PreserveSingleQuotes(form.date_assigned))#,
#str_date_closed#, '#form.addressedto#', '#File.ServerFile#',
'#form.draft#', 'Sandy Crisafulli', 'Incomplete')
</cfquery>
James Taavon wrote:
>
> Nope.
>
> Removing Single Quotes gives me the REXX error again. The variable
> "SUB00001" is actually the table name SUBMISSIONS. Could table length
> name have an impact on this problem? Is DB2 AS/400 limited to lengths
> for table names?
>
> DB2 Error Code = -7008
>
> [IBM][CLI Driver][AS] SQL7008N REXX variable "SUBMI00001" contains
> inconsistent data. SQLSTATE=55019
>
> Data Source = "lsar_prod"
>
> SQL = "insert into lsar.submissions (lid, assignedto, constituent,
> doc_date, dead_date, subtype, subject, subjdetail, received, tone,
> enteredby, date_assigned, date_closed, addressedto, documents, draft,
> assignedby, completed) values ('10006', 'Barry Rubin', '', {d
> '2001-05-10'}, {d '2001-05-02'}, '', '', '', '', '', 'Sandy Crisafulli',
> {d '2001-05-12'}, NULL, '', '10006.pdf', '', 'Sandy Crisafulli',
> 'Incomplete')"
>
> "DeVoil, Nick" wrote:
> >
> > Lose the apostrophes round
> > '#CreateODBCDate(form.date_assigned)#'
> >
> > Nick
> >
> > -----Original Message-----
> > From: James Taavon [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, May 21, 2001 3:06 AM
> > To: SQL
> > Subject: Repost with Proper Subject Line: Problems with inserting a date
> > fields (Using Native Driver, AS/400)
> >
> > James Taavon wrote:
> > >
> > > Hello.
> > >
> > > I posted this in CF-Talk list. Looking for some assistance.
> > >
> > > Can anybody tell me why I am getting this error?
> > >
> > > Thanks,
> > >
> > > James
> > >
> > > <cffile action="UPLOAD" filefield="documents"
> > >
> > destination="/inq2/netscape/suitespot/intranet-docs/dllr/secured-docs/lsar/p
> > df"
> > > nameconflict="OVERWRITE">
> > >
> > > <cfif #date_closed# IS NOT "">
> > > <cfset str_date_closed = "#date_closed#">
> > > <cfelse>
> > > <cfset str_date_closed = "NULL">
> > > </cfif>
> > >
> > > <cfquery name="NewCase" datasource="lsar_prod">
> > > insert into lsar.submissions (lid, assignedto, constituent,
> > > doc_date, dead_date, subtype, subject, subjdetail, received, tone,
> > > enteredby, date_assigned, date_closed, addressedto, documents, draft,
> > > assignedby, completed)
> > >
> > > values ('#form.lid#', '#form.assignedto#', '#form.constituent#',
> > > '#CreateODBCDate(form.doc_date)#', '#CreateODBCDate(form.dead_date)#',
> > > '#form.subtype#', '#form.subject#', '#form.subjdetail#',
> > > '#form.received#', '#form.tone#', 'Sandy Crisafulli',
> > > '#CreateODBCDate(form.date_assigned)#', #str_date_closed#,
> > > '#form.addressedto#', '#File.ServerFile#', '#form.draft#', 'Sandy
> > > Crisafulli', 'Incomplete')
> > > </cfquery>
> > >
> > > IBM][CLI Driver][AS] SQL0104N An unexpected token "2001" was found
> > > following "". Expected tokens may include: ") ,". SQLSTATE=42601
> > >
> > > SQL = "insert into lsar.submissions (lid, assignedto, constituent,
> > > doc_date, dead_date, subtype, subject, subjdetail, received, tone,
> > > enteredby, date_assigned, date_closed, addressedto, documents, draft,
> > > assignedby, completed) values ('10006', 'Barry Rubin', '', '{d
> > > '2001-05-11'}', '{d '2001-05-09'}', '', '', '', '', '', 'Sandy
> > > Crisafulli', '{d '2001-05-03'}', NULL, '', '10006.pdf', '', 'Sandy
> > > Crisafulli', 'Incomplete')"
> > >
> > >
> >
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists