Performance hit on opening Oracle Data Table due to metadata query using PL/SQL
Posted: Thu 11 Feb 2016 08:41
For some time now we have been noticing this quaint little piece of PLSQL being executed when opening an data table where we provided the SQL queries and Column information. We traced it down to the following method:
protected override DataTable GetSchemaTable()
We have been looking for an off switch for this code being called. Unfortunately, we found none except for overriding it with our own implementation which returns an empty data table.
Returning an empty data table as the schema table doesn’t seem to hurt. So we have the following questions:
1. Is there a reason for the unnecessary (and expensive) metadata query?
2. Is anything going to bite us not having the metadata in this table?
3. Would you be willing to implemented like a SkipMetaDataQuery flag?
All the best,
protected override DataTable GetSchemaTable()
We have been looking for an off switch for this code being called. Unfortunately, we found none except for overriding it with our own implementation which returns an empty data table.
Returning an empty data table as the schema table doesn’t seem to hurt. So we have the following questions:
1. Is there a reason for the unnecessary (and expensive) metadata query?
2. Is anything going to bite us not having the metadata in this table?
3. Would you be willing to implemented like a SkipMetaDataQuery flag?
All the best,