Hi Guys,
I gonna write a "Join" query & create a "View" on it. Now, I want to query the data from MySQL's "Views" & use it in my Appian application. Thanks in advance.
Discussion posts and replies are publicly visible
Thanks for replying salim in more info its showing
<<<
The data source schema does not match the type mappings: Missing column: a_id in Appian.losviewpractice (APNX-2-4056-000)
>>>
my column is named " id " actually not "a_id" like it shows in error message, thought you should know
this means in the cdt, you did not mention which column is primary key. update the corresponding cdt and mark column id as primary key. You should then be able to publish the datastore
Thank you salim, I got it
Some additional context: Appian requires you to define a field as a PK in order to map it to a data store entity. It's also required for several other parts of Appian (e.g. as the source of a recordv type). However, a DB View doesn't have a concept of a PK field, so you often will need to construct a field in your DB view that is unique to act as the PK in Appian.
The error that you're seeing about "a_id" is Appian's attempt to automatically add a PK field for you. If you have a table, Appian on publish of the data store Appian can actually alter the table to add this as a PK. However, a database view wouldn't allow this (since it isn't a table), so that's why you're seeing this error.