[Info-ingres] One up unique number for an attribute - in SQL - does anyone know the trick of doing this?

Allan Biggs Allan.Biggs at GBR.dupont.com
Mon Feb 6 15:42:26 UTC 2017


in command line sql I am populating a new table - one of the columns is a 
sort order 

each row of this field  must be a 'one up' unique number starting at 1 and 
ending as the number of rows in the table 


I know that I could do this in OpenROAD , and in another guise this is 
done in OpenROAD,  but in this case it has to be done in SQL or maybe in 
report writer.

It does not matter  which rows contain  1 ,2 etc although one of the 
columns does have a set of unique numbers with gaps which could be used to 
determine the order of row 1, 2 etc. 

Does anyone know of a 'trick' to do this?

In mysql it is possible to define unique one up numbers when creating a 
table does modern Ingres have this feature?

thanks 
Allan 

This communication is for use by the intended recipient and contains
information that may be Privileged, confidential or copyrighted under
applicable law. If you are not the intended recipient, you are hereby
formally notified that any use, copying or distribution of this e-mail,
in whole or in part, is strictly prohibited. Please notify the sender by
return e-mail and delete this e-mail from your system. Unless explicitly
and conspicuously designated as "E-Contract Intended", this e-mail does
not constitute a contract offer, a contract amendment, or an acceptance
of a contract offer. This e-mail does not constitute a consent to the
use of sender's contact information for direct marketing purposes or for
transfers of data to third parties.

Francais Deutsch Italiano  Espanol  Portugues  Japanese  Chinese  Korean

          http://www.DuPont.com/corp/email_disclaimer.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20170206/1982eaec/attachment.html>


More information about the Info-ingres mailing list