I have a view defined in my Oracle database which is a union of two tables. In my code I have a model class defined for the view. When I try to use this class as either the main table or in a relation, the rowid column is automatically added to the SQL statement, but this triggers an Oracle error:
ORA-01446: cannot select ROWID from, or sample, a view with DISTINCT, GROUP BY, etc.
Since the view uses a union, the rowid column isn't valid.
Is there a way to leave rowid out of the generated SQL statement when using a view? I could rewrite my code to use dynamic SQL, but I'd rather use the class.
I'm on Firefly version 33073.