Re: Using Quoted Identifiers
Posted in 1998
On Wed, 17 Jun 1998 dant@wynalda.com wrote:
> In article <6m7035$ibe$1@news.xmission.com>,
> Jonathan Leffler <jleffler@informix.com> wrote:
>
> <<snip>>
>
> > Specific problems:
> >
> > 1. You can only specify the column names in the parenthesized list:
> >
> > INSERT INTO dt_phone("name", "email", "org") ...> >
> > 2. If you use delimited identifiers, you can't use double quotes for
> > strings. The double quotes mark delimited identifiers, and you cannot
> > use identifiers in the VALUES clause of an INSERT statement.
> >
> > ... VALUES ('Fred', 'fred@company', 'company');
> >
> > And, for curiosity's sake:
> >
> > 3. If you specify 'INSERT INTO dt_phone', why do you need to use the
> > quoted form "dt_phone" in the column list?
> >
> > > I am getting an ODBC (-201 syntax) error being returned, but I have tried
> > > the above statement in ISQL and it does not work there either.
> >
> > It looks to me as though you need something more recent than the 1.0
> > version of Powersite. Either that, or your transcription of the problem
> > code is not as careful as it needs to be.
> >
> > Is there a URL for the product?
>
> 1. You are correct that I typed in the VALUES list incorrectly--it is only
> single quoted.
>
> 2. According to posting from the powersoft.public.powersite newsgroup,
> according to the developer of powersite, there is no option of not using the
> double quotes. So I'm stuck with either modifying the generated code or
> making Informix/ODBC accept the code it is given.
Well, as I said in the other posting to which I referred, 'lunacy and baldness
will be close companions'.
Why are they making life unnecessarily difficult for all and sundry?
> 3. Powersite is from Sybase -- www.sybase.com/products/download.html
OK, thanks.
> 4. I'm a little confused from reading your other posting mentioning
> Delimident. Where do I set that variable--ODBC, Informix? And what do I set
> it to--Yes, ' " '?
DELIMIDENT. It is an environment variable. It has to be set where the
ESQL/C or ODBC is in use to stand any chance of working; I don't know where
to set it in a Windows 95/98/NT environment, but I assume it needs to be in
the environment when the Powersite software is run. It can be set to
anything; I'd choose DELIMIDENT=yes (avoid using an empty string).
> Also, where can I find a list of the possible variable to set?
In the manuals. Specifically, Informix Guide to SQL: Reference.
In case of doubt, go to http://www.informix.com/answers for the
manuals.
Yours,
Jonathan Leffler (jleffler@informix.com) #include <witticism.h>
Guardian of DBD::Informix -- see http://www.perl.com/CPAN