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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
sun-sboyanapall
Advocate I
Advocate I

Clickhouse connector - How to query

So I have installed this  connector on my local machine from. 

https://github.com/ClickHouse/power-bi-clickhouse

https://github.com/belyaevvo/ClickHouseConnector

Installed both of them and tried both of them. where I am stuck is there is no option to qrite a qeury, as there is lot of data and with direct connection I would like to utilize paramters to filter the data. 

this is what i got in advanced editor view:
"
let
Source = ClickHouse.Database("0.00.00.00", 8123, "default", null),
default_Database = Source{[Name="default",Kind="Database"]}[Data],
ad_lookup_Table = default_Database{[Name="ad_lookup",Kind="Table"]}[Data]
in
ad_lookup_Table


To this how can I add the Query. so I can filter specific column or ID.

2 ACCEPTED SOLUTIONS
v-nuoc-msft
Community Support
Community Support

Hi @sun-sboyanapall 

 

Please try the following M code:

 

let     
Source = ClickHouse.Database("0.00.00.00", 8123, "default", null),     
default_Database = Source{[Name="default",Kind="Database"]}[Data],     
ad_lookup_Table = default_Database{[Name="ad_lookup",Kind="Table"]}[Data],     
FilteredRows = Table.SelectRows(ad_lookup_Table, each [YourColumnName] = "YourDesiredValue") 
in     
FilteredRows

 

Regards,

Nono Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

okay what i found was If I add a filter it is able to add it to the query. and it is not retrieving all the data before executing. Thank You.

View solution in original post

3 REPLIES 3
sun-sboyanapall
Advocate I
Advocate I

This solution is still goihg to bring in all the data and then query on top of it right?

v-nuoc-msft
Community Support
Community Support

Hi @sun-sboyanapall 

 

Please try the following M code:

 

let     
Source = ClickHouse.Database("0.00.00.00", 8123, "default", null),     
default_Database = Source{[Name="default",Kind="Database"]}[Data],     
ad_lookup_Table = default_Database{[Name="ad_lookup",Kind="Table"]}[Data],     
FilteredRows = Table.SelectRows(ad_lookup_Table, each [YourColumnName] = "YourDesiredValue") 
in     
FilteredRows

 

Regards,

Nono Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

okay what i found was If I add a filter it is able to add it to the query. and it is not retrieving all the data before executing. Thank You.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.