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.
Showing results for 
Search instead for 
Did you mean: 

Mesuring Point's last measuring document

Former Member
0 Kudos

Hi Experts,

I am having 1 measuring point and for that 3 measuring document numbers.I want to take latest document number.

suggest me how to do it.

point : 000000000835

document : 00000000000000001287


I want to take latest 00000000000000001690 pls help me.


Active Contributor
0 Kudos

hi Garima,

you can use:

SELECT MAX( document )

INTO ...

FROM ...


hope this helps


0 Kudos

i am doing like this but it is not working tell me the mistake.

actually i have to select this doc and according to that i have to fetch points position etc.

select single MAX( MDOCM )

from imrg

into corresponding fields of i_mdocm

where idate = dt.

0 Kudos

you can only select one field this way (i. e. with SELECT MAX)

select MAX( MDOCM )

from imrg

into gv_mdocm

where idate = dt.

Now you have mdocm and you can select the whole record with a SELECT SINGLE

An other option would be to select all lines into an internal table, sort the internal table by mdocm descending and now you have highest doc number in the first line of the internal table.

Former Member
0 Kudos


IMPTT is the table storing Measuring point.

IMRG is the table for Measurement documents.