Skip to Content
-1

Problem in data selection with Logical database

Hello All ,

I try to get some posts in BSEG with BKPF Key
GET BSIK
GET BKPF
GET BSEG
append gs_bseg to gt_bseg

i found just the first post for each header bkpf data
so just bseg-buzei = 1

in my case in bseg table i have three posts for a header data

Please , i'm beginner in logical database
can you please provide me an answer to my question

Thanks in advance,
Rachid

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Aug 03, 2017 at 05:51 AM

    Your first GET is GET BSIK so I suppose your are using logical database KDF (?) which only contains the record with vendor account in BSEG node, so usually only one per document, except if you add GET GSEG for offset accounts. If you want every item you must append BSEG and GSEG records to rebuild the full document.

    Hint: As logical database are now obsolete (and rarely used outside of HR) why wouldn't you build you report with direct access to database table so BSIK and BSAK -> BKPF -> BSEG every records.

    NB: In cas of doubt, build a simple test query/dataset with SQ01/SQ02 on the logical database. Or look for statements PUT bseg/gseg in the logical database program. (You should find a SELECT SINGLE with equal BUZEI and a SELECT INTO TABLE with non-equal BUZEI)

    Add comment
    10|10000 characters needed characters exceeded

  • Aug 02, 2017 at 07:38 PM

    Why are you using a logical database? If you have the document number then just do SELECT yourself. It's not clear what you're doing or trying to achieve though.

    Add comment
    10|10000 characters needed characters exceeded

  • Aug 02, 2017 at 04:32 PM
    Add comment
    10|10000 characters needed characters exceeded