Question

Can someone help me to write equivalent criteria query for this

| id |  value1                      | value2                | object_id | property_name
----------------------------------------------------------------------------------------
|    |                              |                       |           |
| 1  | []                           | []                    | 610531    | files
| 2  | Fri Mar 21 00:00:00 2014     | 2014-03-21 12:42:03.0 | 610531    | takenTime
| 3  | []                           | []                    | 610531    | files
| 4  | []                           | []                    | 610531    | files
| 5  | [files:[id:1]]               | []                    | 610531    | files
| 6  | [files:[id:1],[files:[id:2]] | [files:[id:1]]        | 610531    | files
| 7  | abc                          | (NULL)                | 610531    | test
| 8  | [otherfile:2]                | [otherfile:1]         | 610531    | otherfile

here, I having the object_id and I just want to the row (2,5,6,7,8) (i.e) I don't want to extract the row where if

property_name="files" value1="[]" and value2="[]"

I failed in writing criteria query to this.

Was it helpful?

Solution

I found the answer by myself, please correct if any mistake

    or {
            ne("propertyName","files");
            ne("value1","[]")
        }
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top