When I want to create a read only table in the JSF page from a database view, I had created a Entity object using the database View and defined a Primary Key in the EO creation. I drag and drop that view object in the JSF page as a ADF read only table. When I executed the JSF page, I’m getting the error message “ JBO-25013: Too many objects match the primary key oracle.jbo.Key “.
Reason: The reason is there is no column in the database View which is unique. So as I had already defined one of the column as Primary key while creating EO, since that column values are not unique in the table it throws this error.
Solution: Generally, we need to use Entity objects only when we have to do data manipulations (insert, delete, update) in the database tables. For read only access, we no need to use the Entity Objects. The best way to create a read only table in the JSF page from a database view is just create a View Object (based on the sql) on that Database view and you can drag and drop that view object in the JSF page as a ADF read only table. When I did this, the above error was not appearing. It works fine.