dbTalk Databases Forums  

"SELECT FIRST 1" in SPL

comp.databases.informix comp.databases.informix


Discuss "SELECT FIRST 1" in SPL in the comp.databases.informix forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
pretzel
 
Posts: n/a

Default "SELECT FIRST 1" in SPL - 09-28-2011 , 12:41 PM






The following is a singleton SELECT:

"SELECT FIRST 1 blah blah ORDER BY blah blah;"

Why is it forbidden in an SPL?

Curious,

DG

Reply With Quote
  #2  
Old   
Plugge, Joe R.
 
Posts: n/a

Default RE: "SELECT FIRST 1" in SPL - 09-28-2011 , 12:55 PM






You can do the singleton SELECT if you do not have the ORDER BY clause. Ifyou need the ORDER BY clause then you have to wrap it in a FOREACH:

FOREACH
SELECT FIRST 1 blah blah ORDER BY blah blah
END FOREACH

-----Original Message-----
From: informix-list-bounces (AT) iiug (DOT) org [mailto:informix-list-bounces (AT) iiug (DOT) org] On Behalf Of pretzel
Sent: Wednesday, September 28, 2011 12:42 PM
To: informix-list (AT) iiug (DOT) org
Subject: "SELECT FIRST 1" in SPL

The following is a singleton SELECT:

"SELECT FIRST 1 blah blah ORDER BY blah blah;"

Why is it forbidden in an SPL?

Curious,

DG
_______________________________________________
Informix-list mailing list
Informix-list (AT) iiug (DOT) org
http://www.iiug.org/mailman/listinfo/informix-list

Reply With Quote
  #3  
Old   
Jonathan Leffler
 
Posts: n/a

Default Re: "SELECT FIRST 1" in SPL - 09-28-2011 , 02:45 PM



On Wed, Sep 28, 2011 at 10:41, pretzel <davidegrove (AT) gmail (DOT) com> wrote:

Quote:
The following is a singleton SELECT:

"SELECT FIRST 1 blah blah ORDER BY blah blah;"

Why is it forbidden in an SPL?

Curious,


I asked he who knows about such issues, and his response was:

It's a bug. Please ask them to open a case...

I assume this is not a show-stopper but just a nuisancy discrepancy -- is
that fair? That won't stop it being fixed, but may alter its
prioritization. You can discuss that with Tech Support when you open the
case.

--
Jonathan Leffler <jonathan.leffler (AT) gmail (DOT) com> #include <disclaimer.h>
Guardian of DBD::Informix - v2011.0612 - http://dbi.perl.org
"Blessed are we who can laugh at ourselves, for we shall never cease to be
amused."

Reply With Quote
  #4  
Old   
pretzel
 
Posts: n/a

Default Re: "SELECT FIRST 1" in SPL - 10-16-2011 , 04:33 AM



Thank you Joe and Jonathan.

Yes, I realized the work-around. I was just being anal and curious,
as is my wont.

I supposed it might have been a bug that no one ever got around to
fixing because there is an easy work around, and, therefore, many
other things of greater import.

Thanks again.

DG

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.