-
Type: Improvement
-
Resolution: Fixed
-
Priority: Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
Goal
Want to receive a sorted list from db.
Actual Results
App is crashed with this log:
Caused by: java.lang.IllegalArgumentException: Illegal Argument: Invalid predicate: 'TRUEPREDICATE SORT(sort ASC)': syntax error, unexpected sort in /tmp/realm-java/realm/realm-library/src/main/cpp/io_realm_internal_TableQuery.cpp line 527
Steps & Code to Reproduce
For reproduce you can try to create a class that extents RealmObject, add field (var sort: Int = 0). Then try to fetch this objects with query with .sort() function call.
Version of Realm and tooling
Realm version(s): 10.7.1
Realm Sync feature enabled: No
Android Studio version: 2020.3.1
Android Build Tools version: 30.0.3
Gradle version: 7.0.2
Which Android version and device(s): 11