Hi Julio,

You need to use '{call nextval('sequence')}' to ensure broadcast. Sequoia is very generic in its handling of sequences. This call incidentally will block other processing since it's a sproc, and in fact you want that to happen or the calls may be processed out of order on different databases.

If you are using an object/relational mapper like Hibernate you can also switch to another id generator. This results in vastly better performance and is a good practice for Sequoia.

We updated the commercial product uni/cluster to handle this correctly--in addition to recognizing that the nextval call needs to be broadcast you need to parse out the sequence name to ensure ordering.

Robert

Robert Hodges, CTO, Continuent, Inc.
Email:  [EMAIL PROTECTED]
Mobile:  +1-510-501-3728  Skype:  hodgesrm


On Aug 11, 2007, at 10:02 AM, Julio Leyva wrote:

Hi all

Does any one know how to tell sequoia to broadcast select nextval ('sequence') to all the backends?

I have one controller and two backends (postgresql 8.x)

Thanks in advance

JulioC
_______________________________________________
Sequoia mailing list
[email protected]
https://forge.continuent.org/mailman/listinfo/sequoia

_______________________________________________
Sequoia mailing list
[email protected]
https://forge.continuent.org/mailman/listinfo/sequoia

Reply via email to