‎2008 Jan 31 8:03 AM
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
00000000000000001690
I want to take latest 00000000000000001690 pls help me.
‎2008 Jan 31 8:06 AM
hi Garima,
you can use:
SELECT MAX( document )
INTO ...
FROM ...
WHERE ...
hope this helps
ec
‎2008 Jan 31 8:08 AM
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.
‎2008 Jan 31 8:25 AM
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.
‎2008 Jan 31 8:07 AM
Hi,
IMPTT is the table storing Measuring point.
IMRG is the table for Measurement documents.
Regards,
Satish