Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
RehanPattni
New Member

One datasource Multiple Queries

Hi,

 

I have one OLEDB data source with multiple queries. How can I use the same data source for multiple queries

 

Ex.

 

Provider=SQLOLEDB.1;Initial Catalog=XXX;Data Source=YYY;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096;Workstation ID=RRRR;Tag with column collation when possible=False

 

Query 1-

 

Select DISTINCT b.account_name as Account, b.market_segment_id, b.account_type_id
from acnt a left join acnt b on a.parent_account_id = b.account_id
where a.is_active = 1 and a.account_type_id =1
UNION
Select a.account_name as Account, a.market_segment_id, a.account_type_id
from acnt a left join acnt b on a.parent_account_id = b.account_id
where a.is_active = 1 and a.account_type_id = 1 and b.account_name is NULL
Order by Account

 

Query 2-

 

Select * from XYZ where Accnt="RRR"

 

these are just sample queries 

 

The main question is how can I use same data source for multiple queries 

2 REPLIES 2
Greg_Deckler
Community Champion
Community Champion

I would think that you would just create multiple queries? I do this all the time to a single data source.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
RehanPattni
New Member

Hi,

 

I have one OLEDB data source with multiple queries. How can I use the same data source for multiple queries

 

Ex.

 

Provider=SQLOLEDB.1;Initial Catalog=XXX;Data Source=YYY;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096;Workstation ID=RRRR;Tag with column collation when possible=False

 

Query 1-

 

Select DISTINCT b.account_name as Account, b.market_segment_id, b.account_type_id
from acnt a left join acnt b on a.parent_account_id = b.account_id
where a.is_active = 1 and a.account_type_id =1
UNION
Select a.account_name as Account, a.market_segment_id, a.account_type_id
from acnt a left join acnt b on a.parent_account_id = b.account_id
where a.is_active = 1 and a.account_type_id = 1 and b.account_name is NULL
Order by Account

 

Query 2-

 

Select * from XYZ where Accnt="RRR"

 

these are just sample queries 

 

The main question is how can I use same data source for multiple queries 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.