Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Light-hearted exchange on reserved words as identifiers. Jonathan Leffler discussed whether odd SELECT, FROM, TABLE, DATE and NULL names would work in IDS versus DB2, saying he had not tested. Doug Lawry posted a joke SQL statement, Serge Rielau laughed, and Madison Pruet joked it was too complicated. No conclusion.
Auto-generated by Claude from the posts below — may be imperfect; read the full thread.
On 11/28/05, Serge Rielau <srielau@ca.ibm.com> wrote:
> One time is no time, but next time this happens we'll have to get you
> checked for ADD (attention deficit disorder) ;-)
>
> Try this (works in DB2 for LUW):
> CREATE TABLE FROM(SELECT INT);>
> SELECT FROM FROM SELECT;
SELECT SELECT SELECT FROM FROM FROM;
It might work - the first word in each triple is the keyword, the
second is the database object name (column, table), and the third is
the alias.
How does that work in DB2? You created a table FROM with a column
SELECT, not a table SELECT with a column FROM.
> Or
> CREATE TABLE AS(AS INT);
> SELECT AS FROM FROM AS SELECT;
> SELECT AS AS FROM AS AS SELECT;
Those should be OK.
CREATE TABLE TABLE( DATE CHAR(10), NULL INT NOT NULL, DECIMAL INT,INT DECIMAL(23));
That will work.
SELECT DATE, NULL, DECIMAL, INT FROM TABLE;
That might not work; add AS clauses and it might work better.
I'd test it except my IDS server machine needs a power-on password
typed at the keyboard and I'm 1800 miles away from its keyboard - and
I'm too lazy to locate another IDS instance where I am.
sending to informix-list
Doug Lawry wrote:
> Or even:
>
> CREATE TEMP TABLE THIS (YOUR INT);>
> SELECT YOUR FAVOURITE FROM THIS NEWS GROUP BY 1
>
ROFL
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
↪ replying to Jonathan Leffler
Madison Pruet — — source: Usenet: comp.databases.informix
Too complicated for my feeble mind...
"Jonathan Leffler" <jleffler.iiug@gmail.com> wrote in message
news:dmlsvc$9pc$1@news.xmission.com...
>
> On 11/28/05, Serge Rielau <srielau@ca.ibm.com> wrote:
>
> > One time is no time, but next time this happens we'll have to get you
> > checked for ADD (attention deficit disorder) ;-)
> >
> > Try this (works in DB2 for LUW):
> > CREATE TABLE FROM(SELECT INT);> >
> > SELECT FROM FROM SELECT;>
> SELECT SELECT SELECT FROM FROM FROM;
>
> It might work - the first word in each triple is the keyword, the
> second is the database object name (column, table), and the third is
> the alias.
>
> How does that work in DB2? You created a table FROM with a column
> SELECT, not a table SELECT with a column FROM.
>
> > Or
> > CREATE TABLE AS(AS INT);
> > SELECT AS FROM FROM AS SELECT;
> > SELECT AS AS FROM AS AS SELECT;>
> Those should be OK.
>
> CREATE TABLE TABLE( DATE CHAR(10), NULL INT NOT NULL, DECIMAL INT,> INT DECIMAL(23));
>
> That will work.
>
> SELECT DATE, NULL, DECIMAL, INT FROM TABLE;>
> That might not work; add AS clauses and it might work better.
>
> I'd test it except my IDS server machine needs a power-on password
> typed at the keyboard and I'm 1800 miles away from its keyboard - and
> I'm too lazy to locate another IDS instance where I am.
> sending to informix-list
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.