web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Transform data using P...
Power Automate
Unanswered

Transform data using Power Query connector issue

(0) ShareShare
ReportReport
Posted on by 2
Hello All,
 
The usecase is to connect to on-prem sql and get data using Power Automate. Execute a SQL query is not supported and the only way to get data is using Transform data using Power Query.
 
I am using Transform data using Power Query connector but I am not sure in what format I need to provide the query in new designer. The below query works fine when I connect to my on-prem db from excel and it also returns me the data 
 
= let
    Source = Sql.Database("SERVERNAME", "DB NAME"),
    dbo_MYTABLE = Source{[Schema="dbo", Item="MYTABLE"]}[Data],
    FilteredRows = Table.SelectRows(dbo_MYTABLE, each [ID] = "1706"),
    Result = Table.SelectColumns(FilteredRows, {"ID"})
in
    Result
 
but when I give the same query in the query input of Transform data using Power Query connector, it gives me error :
 
Failed to retrieve dynamic outputs. As a result, this operation's outputs might not be visible in subsequent actions. Error details: The dynamic operation request to API 'sql' operation 'SqlGetPassThroughPQMetadata' failed with status code 'BadRequest'. This may indicate invalid input parameters. Error response: { "error": { "code": 400, "message": "Error while processing request body: Unexpected character encountered while parsing value: E. Path '', line 0, position 0.", "source"....
 
I have tried the old designer but I am not sure how to pass a custom query in that.

Please can someone share, how to pass a simple custom query as input and get data.
 
Thanks in advance!
Categories:
I have the same question (0)
  • lbendlin Profile Picture
    8,474 Super User 2025 Season 2 on at
    What made you decide not to use the native SQL connector?
  • CU26111046-0 Profile Picture
    2 on at
    Hello,
     
    As mentioned in my post, native SQL connector is not supported for on-prem database.
     
    Thanks!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard