|
Posted by Weyus on 06/22/07 22:42
On Jun 22, 5:33 pm, Weyus <w...@att.net> wrote:
> All,
>
> Just want to make sure that I understand what's going on here.
>
> I have a table with IGNORE_DUP_KEY set on a unique, multi-column
> index.
>
> What I'm seeing is this:
>
> 1) When performing a BULK INSERT, the UNIQUE index is not being
> respected and rows which violate the unique index are inserted.
>
> 2) When performing a regular INSERT, the UNIQUE index is being
> respected and rows which violate the unique index ARE NOT inserted.
>
> Is this expected behavior.
>
> Also, I have some questions, given the index described.
>
> Q1) Will a regular INSERT that attempts to insert duplicate data get
> an error back or just a warning?
>
> Q2) How can I set things up so that a BULK INSERT would NOT allow
> duplicates to be entered into the table?
>
> Thanks,
> Wes Gamble
I made a logical error that I just realized. The BULK INSERT that I
was doing, in fact did have unique enough data.
However, my question Q1 still stands - what is the behavior of an
INSERT of duplicate data against this type of index - I suspect that
you get a warning
and not an error - is that correct?
Thanks,
Wes
[Back to original message]
|