Subject: Issue Importing MongoDB Data into Power BI
Hello MongoDB community,
I’m encountering an issue importing data from MongoDB into Power BI and would appreciate the community’s assistance in resolving it.
Currently, I am using Power BI to create some metrics, and the database I am using comes from MongoDB. In MongoDB, I have three collections: twitterpublicmetrics
, twitterpercentages
, and twitternewmetrics
. All collections have recorded data.
The problem arises when I try to import data from the twitterpercentages
and twitternewmetrics
collections using the following links in the Power Query editor:
= database_Database{[Name="twitterpercentages",Kind="Table"]}[Data]
= database_Database{[Name="twitternewmetrics",Kind="Table"]}[Data]
Upon doing this, I receive the following errors:
-
Error 1:
DataSource.Error: The table has no visible columns and cannot be queried. Details: twitterpercentages
-
Error 2:
DataSource.Error: The table has no visible columns and cannot be queried. Details: twitternewmetrics
Here are some examples of data in the collections to provide more context:
Example data in twitterpublicmetrics:
{"_id":{"$oid":"6555da10b2ae530e91a1fb74"},"posicao":{"$numberInt":"0"},"data":"16/11/2023","horario":"06:00","seguidores":{"$numberInt":"239"},"seguindo":{"$numberInt":"238"},"contagemTweets":{"$numberInt":"160"},"listasParticipadas":{"$numberInt":"4"},"likesRecebidos":{"$numberInt":"173"},"__v":{"$numberInt":"0"}}
Example data in twitterpercentages:
{"_id":{"$oid":"65572b90b2ae530e91a1fb7b"},"posicao":{"$numberInt":"1"},"data":"17/11/2023","horario":"06:00","aumentoSeguidores":{"$numberDouble":"0.8368200836820083"},"aumentoSeguindo":{"$numberInt":"0"},"aumentoTweets":{"$numberInt":"0"},"aumentoListas":{"$numberInt":"0"},"aumentoLikes":{"$numberInt":"0"},"__v":{"$numberInt":"0"}}
Example data in twitternewmetrics:
{"_id":{"$oid":"65572b90b2ae530e91a1fb7d"},"posicao":{"$numberInt":"1"},"data":"17/11/2023","horario":"06:00","novosSeguidores":{"$numberInt":"2"},"novosSeguindo":{"$numberInt":"0"},"novosTweets":{"$numberInt":"0"},"novosListas":{"$numberInt":"0"},"novosLikes":{"$numberInt":"0"},"__v":{"$numberInt":"0"}}
Error:
Does anyone have any ideas on how to resolve these errors? I appreciate any assistance!
Best regards,
Vinícius Costa