Sure, this is my h2 Script:

CREATE TABLE "SOMETHING_TABLE"
  (
    "COLUMN1"           CHAR(10 BYTE),
    "COLUMN2"       CHAR(10 BYTE),
    "COLUMN3"          CHAR(2 BYTE),
    "COLUMN4"    VARCHAR2(9 BYTE)
  )

ALTER TABLE CMASTER ALTER COLUMN COLUMN1 SET NOT NULL;

  
CREATE UNIQUE INDEX "PK_SOMETHING_TABLE" ON "SOMETHING_TABLE"
  (
    "COLUMN1", "COLUMN2", "COLUMN3"
  )


El viernes, 7 de octubre de 2016, 5:19:08 (UTC-3), Steve McLeod escribió:
>
> H2 does restrict inserts according to UNIQUE index constraints.
>
> Can you post complete reproduction steps?
>
>
>
> On Wednesday, 5 October 2016 18:44:38 UTC+2, Rodrigo wrote:
>>
>> I'm trying to add this statement in my h2 script:
>>
>> CREATE UNIQUE INDEX "SOME_NAME" ON "SOME_TABLE_NAME" (COLUMN1,COLUMN2)
>>
>> Looks like it is being bypassing, because I was able to insert two 
>> identical rows in my h2, but not in my actual DB (Oracle).
>>
>> Is there a way to create that UNIQUE INDEX?
>>
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to