Hi guys,

if a create unique index on column, which is not primary key, it is make from this column, after put index on it, primary key ? Or, just to avoid duplicate data in this column?

Views: 138

Reply to This

Replies to This Discussion

Usually a unique index that is not a primary key is created to just avoid duplicate data. There can be cases where SQL access can happen via the unqiue index rather than primary index.

If the new column must be part of the primary key then it should be added there . But this all depends on application design. 

Thank you

Regards

Eswar

RSS

Bringing Db2 enthusiasts together virtually. Expert or novice, distributed or mainframe, this is the place for everything DB2.

Forum

Db2 LUW 11.1 - GET_LINE procedure - NO_DATA_FOUND exception SQLSTATE

Started by Gagan Kakkar in Application Development and DB2. Last reply by Douglas J. Partch, Jr. Jan 6. 1 Reply

Hi there,I am testing this stored procedure using Db2 11.1 on Windows 10 64-bit.Informational tokens are "DB2 v11.1.4050.859", "s1911120100","DYN1911120100WIN64", and Fix Pack "5".For NO_DATA_FOUND exception I am getting SQLSTATE = 'ORANF' but in…Continue

Tags: modules, Built-in, LUW, Db2

Db2 Analytics Accelerator Version 7.5 is now Generally Available!

Started by Patricia Zakhar in What's hot ? Dec 9, 2019. 0 Replies

Now Generally AvailableIBM Db2 Analytics Accelerator Version 7.5! The latest version of the Db2 Analytics Accelerator, which delivers the highly anticipated Integrated Synchronization capability, is now generally available. The Db2 Analytics…Continue

© 2020   Created by Surekha Parekh.   Powered by

Badges  |  Report an Issue  |  Terms of Service