This website is not affiliated with, sponsored by, or approved by SAP AG.

Getting data from the combined tables

Development (ABAP Development WorkBench, ABAP/4 programming)

Moderators: Snowy, thx4allthefish, YuriT, Gothmog

Getting data from the combined tables

Postby rpinxt » Mon Sep 28, 2015 3:49 am

I connected BSIS with BSAS where BSIS is my main table (I use the fields from BSIS).
However when I call the BSIS document number in my output I get only the BSIS lines and not the cleared lines from BSAS.

I would expect because I joined the tables and the documentnumbers are the same it would get the dat from both tables.

How can I tell the query to pull the data for that documentnumber from BSIS as wel as from BSAS? :?:
rpinxt
 
Posts: 146
Joined: Mon Jul 23, 2012 8:02 am

Re: Getting data from the combined tables

Postby rpinxt » Tue Sep 29, 2015 4:43 am

Ok maybe this cannot be done?

I want to do this because BSIS and BSAS table have better performance then BSEG table.
However we have Journal Entries which have lines on GL accounts which get cleared and lines on GL accounts that not get cleared.
So its a combined Journal Entry.

As I want my report (based on BSIS and BSAS) to report the entire Journal Entry I have a problem when I drive on BSIS-BELNR or BSAS-BELNR.
Because either the BSIS lines or the BSAS lines will not come in...
rpinxt
 
Posts: 146
Joined: Mon Jul 23, 2012 8:02 am

Re: Getting data from the combined tables

Postby Gothmog » Wed Sep 30, 2015 3:47 am

I guess you don't want a join between BSIS and BSAS, you want the union of the lines selected either in BSIS or BSAS.
In a program, it's easy, but I think you're working in a query here ?
No luck without so heavily hijacking the additional coding points that you'd much easier write a program.
And no logical database does it for you, either.

You'll have to do without the index tables, or use two separate queries.
68 74 74 70 3a 2f 2f 74 69 6e 79 75 72 6c 2e 63 6f 6d 2f 62 64 6f 37 6d 77 67
Gothmog
 
Posts: 1941
Joined: Wed Sep 12, 2007 4:46 am
Location: Probably not home

Re: Getting data from the combined tables

Postby rpinxt » Wed Sep 30, 2015 3:55 am

Well not sure if I understand you correct Gothmog.
But I did create an infoset with BSIS and BSAS joined.

What I want is that when I run the report for an accounting document number that it reports me the complete journal entry.
Now it only reports me the lines for BSIS.
Most likely because in the selection I use field BSIS-BELNR.

But I would think because I linked in the join BSIS-BELNR with BSAS-BELNR I also would get the lines for BSAS table.
Apparently this is not the case.
rpinxt
 
Posts: 146
Joined: Mon Jul 23, 2012 8:02 am


Return to ABAP

Who is online

Users browsing this forum: Google Adsense [Bot] and 12 guests





loading...


This website is not affiliated with, sponsored by, or approved by SAP AG.