Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Open SQL supports Righ outer join?

Former Member
0 Likes
2,024

Hi All,

Does Open SQL supports right outer join?

I have searched on help.sap.com but did not found any reference for the same.

If not, any idea why is this not supported?

Thanks,

Piyush

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,191

Hi Piyush,

The obvious starting point for such investigations is the online ABAP help, because it's fast and easy - you know already the keyword (SELECT), so just do a F1 in the ABAP editor and check out what it says.

Anyhow, you'll find the online ABAP help also on the web, check out the [SELECT - join|http://help.sap.com/abapdocu_70/en/ABAPSELECT_JOIN.htm] link, where it is explained that open SQL supports outer joins (though you cannot use multiple outer joins).

Cheers, harald

7 REPLIES 7
Read only

Former Member
0 Likes
1,192

Hi Piyush,

The obvious starting point for such investigations is the online ABAP help, because it's fast and easy - you know already the keyword (SELECT), so just do a F1 in the ABAP editor and check out what it says.

Anyhow, you'll find the online ABAP help also on the web, check out the [SELECT - join|http://help.sap.com/abapdocu_70/en/ABAPSELECT_JOIN.htm] link, where it is explained that open SQL supports outer joins (though you cannot use multiple outer joins).

Cheers, harald

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,191

Hi Harald,

The OP wants to know why RIGHT OUTER JOIN is not supported in Open SQL. I assume the OP knows about the LEFT OUTER JOIN statement.

I think the RIGHT OUTER JOIN is same as the LEFT OUTER JOIN with the RHS & LHS tables interchanged. Please correct me if i am wrong.

BR,

Suhas

Read only

0 Likes
1,191

Hi Suhas / Harald,

Yes, LEFT OUTER JOIN is already supported and we are using this in our application as well.

From SQL perspective it's tables interchanged, but constraint comes when the same table has to participate in more than one join - as if it has already participated on right side of the join.

What i wanted to know was support for RIGHT OUTER JOIN in open SQL , as in the docu help also they mentioned only LEFT OUTER JOINS.

Thanks,

Piyush

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,191

I don't think that RIGHT OUTER JOIN is available in Open SQL. Anyways i don't get this point:

but constraint comes when the same table has to participate in more than one join - as if it has already participated on right side of the join.

Can you explain in detail ?

BR,

Suhas

Read only

0 Likes
1,191

Ah, my bad - missed the right part...

Though I don't really see any difference between the left and right outer join, because you should always be able to rearrange your sequence of the select (based on the unchangeable priority of the joins you might be forced to define a dictionary view in some cases). The part that is in my opinion the real restriction is that you can only have one outer join and that open SQL doesn't allow you to define any conditions on the outer join table (e.g. like the simple scenario where you want to use an outer join to find table entries in one table that don't have a corresponding entry in another table).

Anyhow, it's late on my side and maybe I should be more careful with my postings. Hope I didn't blabber.

Read only

Former Member
0 Likes
1,191

Hi Piyush

check this link..http://help.sap.com/erp2005_ehp_04/helpdata/EN/66/f9545ed3654bd4b55bf7a5b9953a53/frameset.htm

best regards.

Marco

Read only

Former Member
0 Likes
1,191

Hi Piyush,

RIGHT OUTER JOIN is one of the JOIN operations that allow you to specify a JOIN clause. It preserves the unmatched rows from the second (right) table, joining them with a NULL in the shape of the first (left) table. A LEFT OUTER JOIN B is equivalent to B RIGHT OUTER JOIN A, with the columns in a different order.

Regards

Karthick.