After page validation stops further page processing of a Master Detail page, I get the following Oracle Error on display of the Detail portion :
ORA:01445: Cannot select ROWID from, or sample, a join view without a key preserved table.
ORA-06510 - PL/SQL unhandled user-defined exception.
Any clues as to why this might occur? The Master portion of the page displays fine along with the appropriate custom validation error message. It is just the detail portion (from a SQL based report) that is causing the problem. I do not use a ROWID either!
Is the detail portion of your master-detail form based on a standard table or a view? And are you using the built-in tabular form validations, or custom PL/SQL validations? APEX automatically includes the ROWID when using the built-in tabular form validation types, and in that case, certain kinds of views are not support. To get this to work, you would need to remove the built-in tabular form validation and use custom validations instead, or change the view you detail tabular form is based on.
Well, I tried that solution of disabling validations and that's not it. I even rewrote my custom validation so that it returned values no matter the result of the validation (either TRUE or FALSE) and still I get the same error. I have disabled all the validations on the page with the exception of my custom validation. The only validation that is running on my MASTER Detail page is my custom validation. I still get the report error on the Detail section even though all I am doing is reading the data. Still not sure what the error could be.
Just an FYI for everybody who may have this very same problem in the future. I fixed the error and it had nothing to do with ROWID or views or anything like that. Under the Page Rendering section where you define the region definition under the source section, I had included the 'order by' clause in my SQL statement. This was the cause of my ORA-01445 error! When I removed the clause from the source definition and instead included it within the Report Attributes by checking the Sort box for the appropriate column (thus allowing APEX to generate the sort for me), the error disappeared! The Oracle error message would NEVER have given me a clue into what caused the error. I just happened to think 'what if I take the order by clause out'! How's that for a flukey fix!