Skip to Content

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

CDS Create Identity Column within entity

Hello everyone,

i set up one database model on my hana trial instance. but within the cds syntax i am not able to find to define autoincrement functionality to the key column. somebody how to implement this?

Suppose i have the following entity:

entity A {

key column1: Integer,

column2: String(10)



Best regards,

Manjinder Singh

Former Member

You do not have to reference it in the CDS file. The sequence is independent from the entity. When you do an insert into your entity table you have to supply the field for which you wanna use the incremented value with the next value of the sequence.

Best Regards,


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