extra running sql by component

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
saitsari
Posts: 8
Joined: Tue 12 Jul 2011 14:03
Location: turkiye
Contact:

extra running sql by component

Post by saitsari » Wed 11 Apr 2012 14:46

hi,
I upgraded our component 5.5 to 8.14.
but some queries are slower in 8.14.
I catch the sql by sql monitor.
I find some extra queries that sended by component and it take long time
around 1 second. So that it causes forms opening time is take long time.

For example as follows:

Timestamp: 13:26:33.503
SELECT '' TABLE_CATALOG, IC.TABLE_OWNER TABLE_SCHEMA, IC.TABLE_NAME, '' INDEX_CATALOG, IC.INDEX_OWNER INDEX_SCHEMA,
IC.INDEX_NAME, IC.COLUMN_NAME, IC.COLUMN_POSITION, DECODE(IC.DESCEND, 'ASC', 0, 1) DESCENDING FROM SYS.ALL_IND_COLUMNS IC,
SYS.ALL_INDEXES I WHERE IC.TABLE_OWNER = 'HASTANE' AND IC.TABLE_NAME = 'HASTARND' AND I.UNIQUENESS = 'UNIQUE' AND I.OWNER =
IC.INDEX_OWNER AND I.INDEX_NAME = IC.INDEX_NAME ORDER BY IC.INDEX_OWNER, IC.TABLE_OWNER, IC.TABLE_NAME, IC.INDEX_NAME,
IC.COLUMN_POSITION
----------------------------------
Timestamp: 13:26:34.379

bork
Devart Team
Posts: 649
Joined: Fri 12 Mar 2010 07:55

Post by bork » Thu 12 Apr 2012 09:36

Hello

ODAC uses this query to detect primary key or any other unique index, that is required for generating Update, Insert or Delete SQL. Please, try to set the KeyFields property manually. In this case ODAC will not run this additional query.

If this solution doesn't help, then, please, send us Delphi code, that reproduces your issue and the SQL script for creating a table or tables, which are used in your sample.

Post Reply