Steve Crawford wrote:
begin;
select item-id, item-info
from the-queue
where available
order by priority
limit 1
for update;
update the-queue
set status = 'assigned'
where item-id = previously-selected-item-id;
commit;
I do something similar in one of my apps:
BEGIN;
up
Matthew Peter wrote:
Is it possible to automatically detect the language encoding of incoming
data? For instance if Japanese is used, is there a way to know it is
Japanese from a bit in the charset, a dictionary-based evaluation or
otherwise?
Have a look at http://www.mozilla.org/projects/i
[EMAIL PROTECTED] wrote:
Is it possible to define a complex return type like a record in a function
without having some table around with the needed structure of the return
values?
Sure, you just have to specify the columns at select time instead (and
this is easy enough to wrap inside a view)
Phillip Tornroth wrote:
In case it's useful information, the test database is pretty small...
Maybe 15 or 20 megs. The unit tests are individually pretty small.. Less
than 100 inserts each, for sure... So there's not that much to 'roll
back'.. As far as using transactions to undo the state of t
Tomasz Ostrowski wrote:
On Wed, 26 Jul 2006, Tom Lane wrote:
"Antimon" <[EMAIL PROTECTED]> writes:
As the id field is primary key, it should generate a unique violation
if duplicate ids created, might be seen rarely but wanted to solve it
anyway.
Why don't you just use a serial generator?
I
Hi,
I have a number of large tables in a schema all of which are related by
foreign keys.
Now, what I would like to be able to do is run some long-running queries
(mostly selects, but also some updates and inserts into the tables), to
generate some reports which will eventually be rolled-bac
Hi,
I noticed that PG 8.1 beta has been released. With 8.0 I have problems
with code points above U+. Can someone please tell me whether the
Unicode problems in 8.0.x have been fixed in this version?
If so, is the beta version stable enough to use yet?
LL
---(en