Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Number Range: RH_GET_NUMBER_RANGE

Hi All,

I need to know the last transaction number generated for a particular transaction type.

from the following sdn link I came to know that 'RH_GET_NUMBER_RANGE' is the relavant FM for this.

How to generate Transaction ID / Object ID ?

Inorder to execute the FM I need to know the parameters to be passed, they are..

NO_RANGE_NUM

OBJECT_TYPE

PLAN_VERSION

all are char 2..

Can Anyone Help ?, Points will be rewarded..

Thanks in advance, Sudeep..

Tags:
Former Member replied

Hi Sudeep,

This FM gets you the number range based on the import parameters. It wont solve your pupose.

Check out table NRIV which stores all the number ranges. You might get some idea how to get the last number generated.

SELECT SINGLE * FROM NRIV WHERE OBJECT    EQ RP_PLAN
                                 AND  SUBOBJECT EQ SUBOBJECT
                                 AND  NRRANGENR EQ NO_RANGE_NUM
                                 AND  TOYEAR    EQ '0000'.

Or else you can get it from the Parameter id of the transaction number. Just do a get <parameter> id.

Hope it helps.

Lokesh

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question