Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Default strategy for PostgreSQL(How to define default strategy for PostgreSQL?)
Default strategy for PostgreSQL [message #842508] Thu, 12 April 2012 11:08 Go to next message
Miguel Goncalves is currently offline Miguel GoncalvesFriend
Messages: 3
Registered: April 2012
Location: Portugal
Junior Member

How to define default strategy for PostgreSQL?
Currently i have to indicate strategy for all @GeneratedValue annotation.
I'm using PostgreSQL 9.1, EclipseLink 2.3.2.


Miguel Goncalves
Re: Default strategy for PostgreSQL [message #846661 is a reply to message #842508] Mon, 16 April 2012 14:53 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

If you use AUTO or just @GeneratedValue the default will be used.

I think you can customize this default by using a SessionCustomizer and calling setDefaultSequence() on the Session's login.

Otherwise you can customize your PostgreSQL platform by creating a subclass and override createPlatformDefaultSequence().

James : Wiki : Book : Blog : Twitter
Previous Topic:Default Allocation size for sequence
Next Topic:ClassDescriptor.getTable() NULL
Goto Forum:

Current Time: Sun Mar 29 22:49:58 GMT 2020

Powered by FUDForum. Page generated in 0.03363 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top