Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
3 replies
Subscribers
7 subscribers
Views
2309 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
General
I have 2 columns in a table that needs to be sequence generated, I have used @Id
Navajith K
over 11 years ago
I have 2 columns in a table that needs to be sequence generated, I have used @Id and @GeneratedValue and @SequenceGenerator annotations for the first column in the xsd file and its working fine, however for the second column we have @GeneratedValue and @SequenceGenerator annotations, but the value is not sequentialy generated, its putting null values in this coulumns, Any thoughts?...
OriginalPostID-104027
OriginalPostID-104027
Discussion posts and replies are publicly visible
0
Aleksi White
Appian Employee
over 11 years ago
The SequenceGenerator annotation is only compatible with the following RDBMS'
Oracle DB
IBM DB2
More information at:
wiki.eclipse.org/.../PrimaryKey
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Navajith K
over 11 years ago
Thanks Aleksi, We are using Oracle DB, please let us know if we can have more than one sequence generated columns in one table?, We belive that we wont be able to use morethan one @Id annotation in the xsd file.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Aleksi White
Appian Employee
over 11 years ago
From the Oracle documentation: "Defines a primary key generator that may be referenced by name when a generator element is specified for the GeneratedValue annotation. A sequence generator may be specified on the entity class or on the primary key field or property"
It looks like the @SequenceGenerator can only be used with the primary key field
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel