Data storing as Flat Relation ship or not

Hi All,

I have a CDT called

ABC

ID  Name

and DEF

ID  name1  ABC(type ABC)

now is it better to store it in Appian DB as

to separate tables like

ID NAME

and

ID NAME ABC_ID(number which is created manually not by appian)

or storing it as with the ID created by Appian.

 

which is the best way and what are the pros and cons.

TIA :)

Harsha

  Discussion posts and replies are publicly visible

Parents
  • +1
    Certified Lead Developer
    I agree with Mike.
    It is best to avoid nesting (when possible) and definitely should not nest more than one level deep. When you create a 'flattened' CDT structure you have the ability to normalize to the level you need, you can create views to optimize queries, and you can access the data you needed when/where you need it (keeping your footprint in Appian smaller and helping performance). Just don't forget to create the table constraints (foreign keys) and indexes needed to optimize the data structure.
    You should also create you own primary key fields (and use something other than "ID" like "tableAID", as ID is a reserved word in some DB types). When creating your own PKs, you give yourself the ability to access / use the ID.
  • Thanks all for the replies will implement accordingly
Reply Children
No Data