[AccessD]

John Bartow john at winhaven.net
Mon Nov 17 23:55:19 CST 2003


Borge,
Thanks, that's a good point. I'm padding the variable with quotes after I
build it to cover all possible problems.

jb

> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Borge Steen
> Hansen
> Sent: Monday, November 17, 2003 11:46 PM
> To: Access Developers discussion and problem solving
> Subject: Re: [AccessD]
>
>
> I don't know if this is relevant for you, but if the textstring that your
> string variable holds may contain single quote (like in "Sandy's
> Order") you
> need to handle that as well in your sql string....
> regards
> Borge
>
>
> ----- Original Message -----
> From: "John Bartow" <john at winhaven.net>
> To: "Access Developers discussion and problem solving"
> <accessd at databaseadvisors.com>
> Sent: Tuesday, November 18, 2003 3:08 PM
> Subject: RE: [AccessD]
>
>
> > Well, in a way you all did remove brainlock. Got me off of checking the
> > syntax and onto troubleshooting it, the way I should've been. I
> needed to
> > add some single quotes when building the string variable
> "strNewEventName".
> >
> > Thanks!
> > jb
> >
> > > -----Original Message-----
> > > From: accessd-bounces at databaseadvisors.com
> > > [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of John Bartow
> > > Sent: Monday, November 17, 2003 10:38 PM
> > > To: Access Developers discussion and problem solving
> > > Subject: RE: [AccessD]
> > >
> > >
> > > Thanks everyone!
> > > That was quick, went up for another cup of mud and had 4 answers
> already.
> > >
> > > Unfortunatley, you all confirmed that I don't have brainlock.
> It was my
> > > original syntax, (and I think the 5th, 12th and 17th
> attempt's syntaxes)
> > >
> > > Now I have to troubleshoot this thing as to why the SQL statement
> > > is causing
> > > an error.
> > > :o(
> > >
> > > Thanks again.
> > > JB
> > >
> > > > -----Original Message-----
> > > > From: accessd-bounces at databaseadvisors.com
> > > > [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of
> John Bartow
> > > > Sent: Monday, November 17, 2003 9:42 PM
> > > > To: AccessD
> > > > Subject: [AccessD]
> > > >
> > > >
> > > > I need someone to unlock my brainjam!
> > > >
> > > > "strNewEventName" is a string variable I need to insert in this
> > > statement
> > > > and after a half an hour I can't seem to get the syntax correct.
> > > >
> > > > DoCmd.RunSQL "INSERT INTO tblEvent ( fldName, " & _
> > > >             "fldEvTypeID, fldOccur, fldLocation, " & _
> > > >             "fldDesc, fldDeptID, fldRecorded, " & _
> > > >             "fldStaffID ) " & _
> > > >             "SELECT strNewEventName AS fldName, tblEvent." & _
> > > >             "fldEvTypeID, tblEvent.fldOccur, tblEvent." & _
> > > >             "fldLocation, tblEvent.fldDesc, tblEvent." & _
> > > >             "fldDeptID, tblEvent.fldRecorded, " & _
> > > >             "tblEvent.fldStaffID " & _
> > > >             "FROM tblEvent;"
> > > >
> > > > TIA
> > > > JB
> > > >
> > > >
> > > > _______________________________________________
> > > > AccessD mailing list
> > > > AccessD at databaseadvisors.com
> > > > http://databaseadvisors.com/mailman/listinfo/accessd
> > > > Website: http://www.databaseadvisors.com
> > > >
> > > >
> > >
> > >
> > > _______________________________________________
> > > AccessD mailing list
> > > AccessD at databaseadvisors.com
> > > http://databaseadvisors.com/mailman/listinfo/accessd
> > > Website: http://www.databaseadvisors.com
> > >
> > >
> >
> >
> > _______________________________________________
> > AccessD mailing list
> > AccessD at databaseadvisors.com
> > http://databaseadvisors.com/mailman/listinfo/accessd
> > Website: http://www.databaseadvisors.com
>
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>
>




More information about the AccessD mailing list