Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

HANA Unique Index gets not generated using PD

Hi,

I would need to get sure, I'm not doing anything wrong.

We have a simple HANA table with one unique index on it:

Now, we are generating the DDL script for this table... the code for creation of the index gets generated.. but it's not a unique index anymore...

Am I doing something wrong, or is it a bug?

Thanks,

Rafal

Former Member
replied

Hi Rafal

i dont know if its a bug or a feature

but here is the fix:

Please Backup the file Hanadb10.xdb before doing this quickfix!

go to Database>Edit current dbms

locate to SAPHANA10::Script\Objects\Index\Create

you will see:

.if (%Parent.isCatalogTable%==true)

create[ %INDEXTYPE%] index %INDEX% on [%TABLQUALIFIER%]%TABLE% (%CIDXLIST%)[%DescIndex%? desc]

.endif

in the value window

change it like this:

.if (%Parent.isCatalogTable%==true)

create[ %UNIQUE%][ %INDEXTYPE%] index %INDEX% on [%TABLQUALIFIER%]%TABLE% (%CIDXLIST%)[%DescIndex%? desc]

.endif

Please Backup the file Hanadb10.xdb before doing this quickfix!

HTH

dj

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question