Hello @Pavankumar-3526 ,
Welcome to the MS Q&A platform.
Please correct me if my understanding is wrong. It seems like you are using ODBC and defined with DNS to access your data source. You are not directly using the driver to query the data.
If you use the driver directly, it works. But if you use the ODBC and DNS to get the data from your data source, then you will get the error message "native queries aren't supported by this value"
Using the driver directly to query the data:
Using the ODBC and DNS, This is expected behavior.
Value.NativeQuery doesn't support ODBC data sources, but ODBC has a special function for the native query.
Odbc.Query(connectionString as any, query as text, optional options as nullable record) as table
Example: Odbc.Query("dsn=your_dsn", "select * from Customers")
output: table
Please see the below document for your reference. Let us know if you have any further questions.
https://learn.microsoft.com/en-us/powerquery-m/odbc-query
------------------------------
- Please don't forget to click on and upvote button whenever the information provided helps you. Original posters help the community find answers faster by identifying the correct answer. Here is how
- Want a reminder to come back and check responses? Here is how to subscribe to a notification
- If you are interested in joining the VM program and help shape the future of Q&A: Here is how you can be part of Q&A Volunteer Moderators