Skip to Content
0

How do I control the order of the tables in the FROM

Dec 11, 2017 at 07:51 AM

31

avatar image

Hi all,

BO 4.2 (WEBI) - Oracle db v11

I have a query that should read:

Select *

From TABLE_A

LEFT JOIN TABLE_B

ON TABLE_A.ID = TABLE_B.ID

AND TABLE_B.VALUE = 'TRUE'

Sadly BO decides to do:

Select *

From TABLE_B

RIGHT JOIN TABLE_A

ON TABLE_A.ID = TABLE_B.ID

WHERE

TABLE_B.VALUE = 'TRUE'

This means I only get data from TABLE_A when the condition in TABLE_B is TRUE.

I have tried:

REVERSE_TABLE_WEIGHT = Y

REVERSE_TABLE_WEIGHT = Yes

SORT_JOINS_BY_QUERY_OBJECTS = Y

SORT_JOINS_BY_QUERY_OBJECTS = Yes

but none of these work.

Any help would be gratefully appreciated.

Thanks

Andy

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

AMIT KUMAR
Dec 11, 2017 at 11:15 AM
0

check attached link or you try with custom SQL in webi.

http://www.dagira.com/2010/08/17/handling-conditions-on-outer-joins/2/

Share
10 |10000 characters needed characters left characters exceeded
Andrew Irving Dec 11, 2017 at 01:13 PM
0

My filter actually has a subquery which stops the param FILTER_IN_FROM from working. I created a derivable table (SELECT * FROM:::) with the filter applied to that and outer join to that

Share
10 |10000 characters needed characters left characters exceeded
Pavan Kumar Pullapanthula Dec 12, 2017 at 07:11 AM
0

Hi Andrew Irving,

Please find images.

Here W_DIST_MDLS(Table_A) is a Left Table and W_STG_PC(Table_B) is a Right table.

BO generated query like as same. Please find the second image. We select W_DIST_MDLS as a left table with LEFT OUTER JOIN. BO take as Right table with RIGHT OUTER JOIN.


Share
10 |10000 characters needed characters left characters exceeded