Q: Automate an sql script in power bi I am using Toad for Oracle 14.2 database it
I have an sql script which checks duplicates and not nulls in various columns (and tables) and returns a count of rows if nulls or duplicates exist.
This data integrity test script is run every two weeks. The script is written in a way that the results of the query are spooled into a text file in a shared folder.
I wish to automate it and schedule its run every two weeks.
I know this can be done in a crontab using Linux.
But I would like to know how could it be achieved using POWER BI with a scheduled refresh
Thank you

A: This is super-easy in Power BI, once you get the Oracle drivers installed on both your dev environment and on the On-Prem gateway you set up.
This would simply be an import mode Dataset with a custom SQL Statements and a scheduled refresh.
You may have to break the script up into multiple queries in Power Query.  If they all return the same columns you can merge them into a single table in the Power BI model.
