Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Query slow via program but fast if executed in database

Former Member
0 Kudos

We are facing a strange issue.

We have 2 custom fields in standard table and the select query has these in the Where clause.

The index is created , activated and adjusted on these 2 fields via SE14.

The query called from function module in quality runs in fraction of milli seconds.

In production it takes 90 seconds.

When we run the query directly in oracle (And also SE16) , it takes fraction of seconds .

I am trying to figure out why the program behaves differently.

1 REPLY 1

Sandra_Rossi
Active Contributor
0 Kudos

For all questions about database query performance, you have to run the SQL trace (transaction ST05), and analyze the execution plan. It may be analyzed by a database administrator.