Re: sql question
Posted in 1993
netters,
sorry for not explaining exactly what i was looking for when i was executing
the following sql:
select * from table where 1 = 2
we have an application that, if requested, will return data in a spread
sheet format by using the informix 'unload' command. the problem with this
is that i need to have column headings as well as the delimited data. so
in a quick attempt to snag the column names, i tried the above statement
expecting to get the results back fairly quickly. no such luck. another attempt
i tried was:
select * from table where tabid = -1
i chose -1 so that the program would run on both online and se. this works
great. after playing around with this concept, i thought that i could just
write a program that 'altered' the original unload script to tack on the
'tabid = -1' statement to the where clause. again, this worked great until
the sql contained an 'order by' or 'group by' clause - then it fails with
a -457 : database terminated unexepectedly.
hope this sheds some light on what/why was being attempted.
regards,
+----------------------------------------------------------------------------+
| . . | |
| ... ... | Bob Baskett |
| ..... ..... | Software Engineer, DBA |
| .. ... .. | Business Systems Integration Group |
| . . . | Semiconductor Products Sector |
| | Mesa, AZ |
| Motorola, Inc. | |
+----------------------------------------------------------------------------+
| 'connectionLESS IS MORE' -- Data Broker |
+----------------------------------------------------------------------------+
| Duct tape is like the force. It has a light side, and a dark side, and |
| it holds the universe together ... |
| -- Carl Zwanzig |
+----------------------------------------------------------------------------+