From: Enrico Ortmann <pg.admin@radax.net>
To: Paul Breen <pbreen@computerpark.co.uk>
Cc: pgsql-admin@postgresql.org
Subject: Re: self defined counter function
Date: Tue, 20 Apr 2004 15:25:40 +0200
Message-ID: <808772948.20040420152540@radax.net> (raw)
In-Reply-To: <57529.10.0.0.61.1082461295.squirrel@mailserver.computerpark.local>
References: <1574570229.20040420095643@radax.net>
<57529.10.0.0.61.1082461295.squirrel@mailserver.computerpark.local>
Hi Paul,
PB> select code from codes where code_urn = (select nextval('code_urn_seq'));
Yes this is a great idea, but it only manages
one character. But I need a counter with
at least a variable length and it has to be
filled with leading zero-values, so that
the length of the generated counter value
is everytime I call the function the same.
Enrico Ortmann
----------------------------------------
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: pg.admin@radax.net, pbreen@computerpark.co.uk
Subject: Re: self defined counter function
In-Reply-To: <808772948.20040420152540@radax.net>
References: <1574570229.20040420095643@radax.net> <57529.10.0.0.61.1082461295.squirrel@mailserver.computerpark.local> <808772948.20040420152540@radax.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox