ODP.NET fails to find primary key on views with UNION operator
Colleagues,
Apologies if this issue is already known; I was unable to find anything pertaining to it in my researches.
The ODP.NET OracleDataAdapter.FillSchema() method populates a DataTable object with the schema of an Oracle view or table. Unfortunately, it fails to transfer the primary keys of some views, particularly those with the UNION operator in their definition. Given the following table and view based on it, ODP.NET for 11.2 returns a zero-length array of primary key columns for the view when a DataTable is created from it. I include source code in C# and SQL that demonstrates the problem. When run on the PRIMARYKEYFAILURE_V view, the code demonstrates that the primary key columns are found in the data dictionary, but