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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
her
Helper III
Helper III

How to Write Mongo Query(Intellishell) in Power BI Using R Script

Hi,

I have more than 3Million Records and mongodb connect via odbc but its performance is very slow,

then i tried connect via  R Script  its connected below query used:

library("mongolite")
m<- mongo(collection= "users", db = "admin", url = "mongodb://admin:root@127.0.0.1:27017", verbose = TRUE)
users<- m$find()

users<-m$find() its working but how to write R Script for getting Count

 

Thanks and Regards

Herwin

 

2 REPLIES 2
v-frfei-msft
Community Support
Community Support

Hi @her ,

 

To be honest, I am not an expert of R, hope the online document can help you.

https://docs.microsoft.com/en-us/power-bi/desktop-r-scripts

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi @v-frfei-msft 

 

Thank you so much your response

 

thanks and regards

Herwin

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.