Forum Discussion
Mer123
2 years agoNew Member
Cannot Load Model
I was wondering if anyone can help with the below problem. I'm using Teradata presto ODBC driver to retrieve data from the source to power bi. The power bi connector I'm using is a custom conne...
amitchandak
Super User
2 years agoMer123 , Native query is not always supported in Direct query.
Sometimes additional steps in power query will stop rolling the native query
Are you using the Standard ODBC driver or some third-party connector?
Mer123
2 years agoNew Member
Hi amitchandak ,
Thanks for your reply.
I'm using a third-party ODBC (Teradata presto ODBC driver) and a custom power query connector.
Below is a sample of the code.
// Use Odbc.Query with the provided NativeQuery
QueryConnectionOptions = [
CredentialConnectionString = EncryptedConnectionString
],
result = if NativeQuery <> null then
// Use Odbc.Query with the provided NativeQuery
Odbc.Query(ConnectionString, NativeQuery, QueryConnectionOptions)
else
// Use Odbc.DataSource if native query is not provided
Odbc.DataSource(ConnectionString, ConnectionOptions)