Skip to Content

Identity column in hdbtable file

Apr 26, 2017 at 11:15 AM


avatar image
Former Member


we are currently migrating our test tables from a schema to a transportable hdbtable-file.

Now we have the problem that we do not find a way to create identity columns. What is the syntax in hdbtable files? Or is there a better way to create tables in a transportable fashion? I mean the normal tables support the identity feature, there must be a way to specify them in the hdbtable files, everything else would be totaly stupid...

10 |10000 characters needed characters left characters exceeded

Is there any updates on this? I am also facing with the issue "unexpected token "genereated"

* Please Login or Register to Answer, Follow or Comment.

3 Answers

avatar image
Former Member May 23, 2017 at 09:19 AM

Good Morning,

I am trying to create the table with a CDS file, but the generated always as identity throws an error. I tried copying the Syntax from the reference but it still throws the error that it is an unexpected token.

Description Resource Path Location Type
[1310001] Syntax error: unexpected token "generated" at line 20, column 20 .xxx Row 20, Column 20 SAP HANA Activation Problem

namespace "xxx"."Catalog"."UP"."TABLES";

@Schema: 'xxx'

context T_UP_CUST_MD2 {


entity T_UP_CUST_MD2 {

"0CUSTOMER_KEY": String(10 )not null;

"CO_BZL_KEY" : String(8);

"CO_AM_KEY" : String(8);

"CO_KAM_KEY" : String(8);

"SALES_OFF" : String(4);

autoId : Integer generated always as identity ( start with 10incrementby2);


Show 1 Share
10 |10000 characters needed characters left characters exceeded

Please can you share what HANA revision you are using.

Krishna Tangudu May 23, 2017 at 05:37 PM

You can remove identity from the definition and try to check

Krishna Tangudu

10 |10000 characters needed characters left characters exceeded
Florian Pfeffer
Apr 26, 2017 at 12:29 PM

The hdbtable configuration syntax does not support the creation of identity columns.

hdbtable objects are already some kind of outdated. The future belongs to Core Data Services (hdbdd files in XSC, hdbcds in XSA). Core Data Service entities supports the creation of identity columns (please check the CDS Reference).


10 |10000 characters needed characters left characters exceeded