SQL generation with two schemas involved fails to generate
OPENJPA_SEQUENCE_TABLE across both schemas for Postgres
------------------------------------------------------------------------------------------------------------------
Key: OPENJPA-1709
URL: https://issues.apache.org/jira/browse/OPENJPA-1709
Project: OpenJPA
Issue Type: Bug
Affects Versions: 2.0.0
Environment: Mac OSX, JDK6, OpenJPA maven plugin
Reporter: Benjamin Renaud
Fix For: 2.0.0
Summary is pretty self explanatory. To reproduce:
- Create two entities, that map to two different schemas, let's say foo and bar.
- Make sure they both have generated ids, something like:
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private long id;
- run the openjpa:sql maven target
The result will have:
CREATE TABLE foo.OPENJPA_SEQUENCE_TABLE (ID SMALLINT NOT NULL, SEQUENCE_VALUE
BIGINT, PRIMARY KEY (ID));
where it should have
CREATE TABLE foo.OPENJPA_SEQUENCE_TABLE (ID SMALLINT NOT NULL, SEQUENCE_VALUE
BIGINT, PRIMARY KEY (ID));
CREATE TABLE bar.OPENJPA_SEQUENCE_TABLE (ID SMALLINT NOT NULL, SEQUENCE_VALUE
BIGINT, PRIMARY KEY (ID));
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.