How to retrieve Case Insensitive data using Retrieve

0
Hello Team, I am trying to validate if the Key entered in my form is already present in the database then I should not be able to enter the data [ProjectName = $inputObject/ProjectName] Know this match is Case Sensitiv If my ProjectName is “Abc”, and now the user is trying to enter the new ProjectName as “ABC” or “aBC” or “AbC” then they would be able to. I want to convert my Input to a common case and compare with Database field in the same format Example : [toUpperCase(ProjectName) = toUpperCase($inputObject/ProjectName)]  
asked
3 answers
6

you need to define this when you create your Database and it depends on which database that you are using: here is a link that you can check out https://docs.mendix.com/refguide/case-sensitive-database-behavior
 

for example, if you are using sql server you still have the chance to change the collation and alter your database to use Case Insensitive, but there is a concern from Mendix that you will have more results from the DB retrieve action.
if changing that is not an option so the above solution by Joshua Choukroun is your way!

 

answered
2

What you can do is to always store the project name in uppercase, then in your microflow you create a string variable like that toUpperCase($inputProjectObject/ProjectName), right after that you retrieve your object comparing this variable with the attribute ProjectName

answered
0

Hi Abhishek,

You can try “contains” function in expression while comparing. contains function is not case sensitive.

hope this will help you.

answered