OQL - Dataset

0
Hello everyone, I'm using dataset to execute oql query and not sure how to do following like statement. I'm not sure what is syntax to do something like this Entity_2.Value like '%Entity.Value%' select Attribute as Attribute from MyModule.Entity_2 as Entity_2 where Entity_2.Number != 0 and not(exists( select * from MyModule.Entity as Entity where Entity.Value like Entity_2.Value and )) Best regards, Slavko
asked
2 answers
0

Hello,  Try to give like condition within two single quotes

So ' in string becomes '' (two single ones). 

select Attribute as Attribute from MyModule.Entity_2 as Entity_2 where Entity_2.Number != 0 and not(exists( select * from MyModule.Entity as Entity where Entity.Value like ''%Entity.Value%'' and ))

 

It is the way to escape a single quote in a string

answered
0

Hi Slavko,

 

Please refer this

https://medium.com/@mohammad.saqib_1262/oql-series-part-1-introduction-to-object-query-language-in-mendix-213a0ff132a6

answered