2
 Followers
3
 Likes

Primary key for multiple columns (Composite keys)

Backend
Not right now

I would like to see the support of using multiple columns as a primary key within OutSystems. This because we have a lot of primary keys that exist of multiple columns in our old system's database. 

Created on 5 Apr
Comments (4)

Tools like Java, C#, etc. have the philosophy of "give the developer enough rope to hang themselves". OutSystems works very hard to keep you inside the limits of "best practices" and "good practices". Look at how hard it is to create a SQL Injection vulnerability, even if it means that dynamic SQL is a lot of effort to make happen. Composite primary keys are definitely not a "best practice" and the platform should NOT want to encourage their use at all by making it possible to do them. At best, this should be supported in Integration Studio because of existing/legacy databases with composite primary keys, but definitely not in Service Studio.

J.Ja

Changed the category to Backend


I agree with Justin that it would be nice to support it for legacy databases, but it should definitely not be possible to create them in OS native Entities. Note that for the latter, you can mimick the behaviour by adding a unique index over multiple columns.

Changed the status to
Not right now


Hi Alexander,

You have this capability creating an index with multiple columns. Is this enough for your use case? 

Thanks

views
1827
Followers
2