Skip to Content

DB hints select query

HI SAP GURUs,

I have a DB HINT select query & I have to change this into OPEN SQL.

But first am not understanding below DB hint query itself. SO request you to please guide me on below.

SELECT FIELD1

FIELD2

FIELD3

FROM ABC

INTO TABLE ITAB

WHERE FIELD1 = VALUE

%_HINTS ORACLE 'LEADING (ABC.T1) USE_NL (ABC.T2)'.

Thanks,

Shabareesh

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Aug 24, 2016 at 11:02 AM

    I don't understand your question.

    What do you mean with

    I have to change this into OPEN SQL ?

    The above statement is already Open SQL.

    The addition "%_HINTS ORACLE" is an addition in Open SQL.

    After the addition, you enter an Oracle specific hint.

    You can enter more than one addition %_HINTS for the same and for other DBs.

    There are no OPEN SQL specific hints (at least no documented ones that you can use).

    See note 129385.

    Horst

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 24, 2016 at 11:27 AM

    If you actually want to understand the Oracle hint, I suggest you first search/read online Oracle documentation (e.g. Understanding Optimizer Hints and Using Optimizer Hints.)

    • Else what do you intend to do? This is already an Open SQL statement (as Horst wrote) , remove the hint, change database for the hint, switch to native sql?
    • Are your Oracle statistics up to date?
    • Could you provide the real statement, LEADING and USE_NL are related to JOIN so your code make no sense for me?

    Regards,

    Raymond

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.