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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Arioli_Chezhian
Helper II
Helper II

SQL query in advanced settings in PBI desktop for Oracle

Hi,
I am using Oracle as data source in PBI desktop.
In oracle the data appeared as shown below:

Arioli_Chezhian_0-1688907272699.png

In PBI desktop am getting the below error:

Arioli_Chezhian_1-1688907319759.png

The query I required is:
Select * From ACTIONLOG
Where LOGGED_TIME >= '01-07-2023';

I tried lot of queries but still getting the above metioned error.
SELECT * FROM ACTIONLOG WHERE LOGGED_TIME >= TO_DATE('2023-07-01');
SELECT * FROM ACTIONLOG WHERE LOGGED_TIME >= TO_DATE('2023-07-01');
SELECT * FROM ACTIONLOG WHERE TO_DATE(LOGGED_TIME) >= TO_DATE('2023-07-01');
SELECT * FROM ACTIONLOG WHERE LOGGED_TIME >= DATE '2023-07-01';

Please advice the correct syntax to be used in PBI desktop in advanced settings to achieve my requirement.
Thanks in advance..!

2 REPLIES 2
amitchandak
Super User
Super User

@Arioli_Chezhian , Try like

 

SELECT * FROM ACTIONLOG WHERE LOGGED_TIME >= TO_DATE('2023-07-01', 'YYYY-MM-DD');

 

in case this does not work check the driver is correct

Topic description have steps

https://community.powerbi.com/t5/Desktop/Getting-Power-BI-Desktop-to-work-with-Oracle-ODAC-after-ver...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi @amitchandak 
SELECT * FROM ACTIONLOG WHERE LOGGED_TIME >= TO_DATE('2023-07-01', 'YYYY-MM-DD');

I tried the above query as well. It's not working. 
Just to add up few more points to give you a better view, only if I try to filter based on this date/time field am getting that error.

Example: if I try to import data based on below query it's working.
SELECT * FROM ACTIONLOG
WHERE USER_NAME IN ('abcd','efgh');

In this case still do you think it's due to the driver issue?

Please advise.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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