Issue while inserting data in third party data source

Hi All

I am working on version 17.2.

I am connecting with a third party data source. I have created a CDT which has the same structure as the table in the third party data source. I am able to select as well as update data in the third party data source. However, when I try to insert data in the table, the primary key value is not generated, i.e. it goes as null thus my process breaks at Write to data store entity; which is expected behavior.

At the third part data source, the primary key is a number which is created as "GENERATED AS IDENTITY NOT NULL". In my CDT I have given the annotation @SequenceGenerator and @GeneratedValue and the CDT is getting verified with the data source.

For reference, the ID column in my XSD is given as:

  <xsd:element name="ID" nillable="true" type="xsd:int">
   <xsd:annotation>
   <xsd:appinfo source="appian.jpa">@Id @GeneratedValue @SequenceGenerator @Column(name="ID", columnDefinition="NUMBER")</xsd:appinfo>
   </xsd:annotation>
  </xsd:element>


Now I want to know how to handle the primary key column i.e. what do I insert as a value in ID column.


Thanks in advance!!

  Discussion posts and replies are publicly visible

Parents Reply Children