Skip to main content
Question

Lobby - datasource join two views


Forum|alt.badge.img+6
  • Do Gooder (Customer)
  • 27 replies
It is possible to join two views when using datasource designer? I want to join customer_order and customer_order_line by order_no. I don’t have query builder.
I am interested to query customer_order where order_ID = ‘xxx’ and in customer_order_line where qty_assigned > 0

 

3 replies

COVJAMIEB
Hero (Partner)
Forum|alt.badge.img+11
  • Hero (Partner)
  • 202 replies
  • March 10, 2023

Hello!

What results do you expect to see?
Do you want to see all customer order lines where qty_assigned > 0 and order_id = ‘ERS’?


BawTrishM
Sidekick (Partner)
Forum|alt.badge.img+6
  • Sidekick (Partner)
  • 18 replies
  • March 10, 2023

Hi @jgrace ,

Here is what we usually do to create datasources using multiple views.

1. Create and deploy an IAL where you'll be placing your SELECT with all the joins required.
Path : Solution Manager > Reporting and Analysis > Information Access Layer > IAL Object

2. Create a quick information source draft from that IAL.
Path : Solution Manager > Reporting and Analysis > Information Sources > Quick Information Sources Drafts > Quick Information Sources

3. Create an information source from the drafted quick information source.
A view will automatically be created at this point. The view name can be obtained in the “Data Access Type Information” group. 
Path : Solution Manager > Reporting and Analysis > Information Sources > Information Sources > Information Source
You will be able to use the view in your datasource.

Regards,
Trishen


Forum|alt.badge.img+20

This is not an answer to the initial question, just a side note:

For those actually wanting to join customer_order and customer_order_line: There is already a view called CUSTOMER_ORDER_JOIN in STD that does that. It may or may not contain the columns you need.

 

For the real question:

If you only need to show data from one view and only need the other one to fetch the correct data you can also do an EXISTS or IN statement in the WHERE clause.

 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings