Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
4 replies
Subscribers
7 subscribers
Views
2163 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
General
I am trying to create a nested CDT with one-to-many relationship for two existin
giridharn
over 8 years ago
I am trying to create a nested CDT with one-to-many relationship for two existing tables and I am having difficulty making it work the way I wanted to. Hope someone can help me with this. The child table in this case has index based on two primary keys.
--- Customer table ---
ID (Primary key)
Name
--- Groups table --- (Primary keys Group_Id, Customer_ID)
Group_Id
Group_Name
Customer_ID
When I use write to datastore, one row is inserted/updated in the parent (expected) and only one row is being inserted/updated in the child table. Please see attached xsd
Appreciate any help
customer.xsd
OriginalPostID-167656
OriginalPostID-167656
Discussion posts and replies are publicly visible
0
Eliot Gerson
Appian Employee
over 8 years ago
What RDBMS are you using? Can you attach a screenshot of the structure of the tables or the SQL script to create the tables? You mention that you are writing to two existing tables. What was the structure of the tables prior to the creation of the nested CDT?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
giridharn
over 8 years ago
Eliot, The database is Oracle. The tables and CDT are sample and not actual tables. We cannot change the structure of these tables as these are used by multiple applications. So the structure is the same before and after CDT creation. Thanks for your response
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Eliot Gerson
Appian Employee
over 8 years ago
Could you provide more information about the specifics of your use case? Without knowing the structure of the tables and the structure of the CDT, it is difficult to diagnose the problem.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
giridharn
over 8 years ago
Eliot, Never mind..I read in the documentation that write to datastore with composite keys is not possible unless you have column with unique values. So I settled for using query database node instead of write to datastore.
forum.appian.com/.../Database_Schema_Best_Practices.html
Thanks
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel