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
16 replies
Subscribers
10 subscribers
Views
9159 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
General
Uniqueness of a field
sergeiz1
over 8 years ago
Hello!
What is the best way to keep some CDT field unique? It will be a constraint in the database, but the database error message is not user friendly.
I can set it up as a query rule or expression and validate manually in the interface. In this case the designer should remember what fields have to be validated.
May be there is an easier and straightforward way to achieve it?
OriginalPostID-273384
Discussion posts and replies are publicly visible
0
sergeiz1
over 8 years ago
> Option 2 is actually not that hard to implement
With option 2 if the process will be cancelled I'll need a manual rollback deleting the record from the database.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sergeiz1
over 8 years ago
I think Appian is not the best tool to tuning database locking and manual transaction management.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
PhilB
A Score Level 1
over 8 years ago
That's correct, it is quite common. However, you usually generate the unique items; in the case of IDs for primary keys, for example, you don't ask the user to enter the unique ID.
I'm guessing you have a requirement for a name to be unique - but my question would be why does it need to be? I'm just curious what the requirement is :)
Appian is quite cabale of implementing locking - optimistic or otherwise - but it does take a bit of work. This might be interesting reading if you've not already seen it:
docs.appian.com/.../Database_Schema_Best_Practices.html
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sergeiz1
over 8 years ago
It's not yet a real requirement, I'm preparing myself for Designer exam and looking around for general ideas. Simple real requirement I can think of is a list of employees. They can have same first name + second name, but the email should be unique.
> This might be interesting reading if you've not already seen it:
docs.appian.com/.../Database_Schema_Best_Practices.html
Oh! Regular JPA @Version.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Stefan Helzle
A Score Level 3
over 8 years ago
@sergeiz: Regarding answering to comments. New Appian community site will be released soon and solve this issue.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sergeiz1
over 8 years ago
@stefanh791 Good!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
<