How do you implement 2 data sources (views) into the lobby data source designer.
I want the following code to return the count in the data source.
select distinct(sp.catalog_no)
from lora1app.sales_part sp,
lora1app.sales_price_part_join splp
where splp.catalog_no = sp.catalog_no and splp.SALES_PRICE_TYPE_DB = 'SALES PRICES'
and sp.activeind_db = 'Y'
and (splp.part_valid_to_date >= (sysdate) or splp.part_valid_to_date is null)
and splp.valid_to_date >= (sysdate)
--currently I have gone about it the following way seeing that the data source cannot handle two views:
select distinct SALES_PART.Catalog_NO from SALES_PART
where SALES_PART.activeind_db = 'Y' and SALES_PART.Catalog_NO in
(select catalog_no from sales_price_part_join where sales_price_part_join.catalog_no = SALES_PART.CATALOG_NO AND sales_price_part_join.SALES_PRICE_TYPE_DB = 'SALES PRICES' and (sales_price_part_join.part_valid_to_date >= sysdate or sales_price_part_join.part_valid_to_date is null) and sales_price_part_join.valid_to_date >= sysdate)
group by SALES_PART.catalog_no
both sets of code are returning in PL/SQL with the same count value. but I receive a single row returns more than one record in subquery error. Please advise what I have wrong and why it is working without duplicate records in pl/SQL. Thanks,