Send feedback
Run SQL Runner Query
Stay organized with collections
Save and categorize content based on your preferences.
Version 4.0.25.14 (latest)
Execute a SQL Runner query in a given result_format.
Request
POST
/sql_queries/{slug}/run/{result_format}
Expand HTTP Path definition...
slug
string
slug of query
result_format
string
Format of result, options are: ["inline_json", "json", "json_detail", "json_fe", "json_bi", "csv", "html", "md", "txt", "xlsx", "gsxml", "sql", "odc", "json_label"]
Expand HTTP Query definition...
download
string
Defaults to false. If set to true, the HTTP response will have content-disposition and other headers set to make the HTTP response behave as a downloadable attachment instead of as inline content.
Response
400: Bad Request
message
lock
string
Error details
documentation_url
lock
string
Documentation link
404: Not Found
message
lock
string
Error details
documentation_url
lock
string
Documentation link
422: Validation Error
message
lock
string
Error details
Expand ValidationErrorDetail definition...
field
lock
string
Field with error
code
lock
string
Error code
message
lock
string
Error info message
documentation_url
lock
string
Documentation link
documentation_url
lock
string
Documentation link
429: Too Many Requests
message
lock
string
Error details
documentation_url
lock
string
Documentation link
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-20 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-20 UTC."],[],[],null,["# Run SQL Runner Query\n\nVersion 4.0.25.14 (latest)\n\nExecute a SQL Runner query in a given result_format.\n\nRequest\n-------\n\nPOST /sql_queries/{slug}/run/{result_format} \nDatatype \nDescription \nRequest \nHTTP Request \npath \nHTTP Path \nExpand HTTP Path definition... \nslug \nstring \nslug of query \nresult_format \nstring \nFormat of result, options are: \\[\"inline_json\", \"json\", \"json_detail\", \"json_fe\", \"json_bi\", \"csv\", \"html\", \"md\", \"txt\", \"xlsx\", \"gsxml\", \"sql\", \"odc\", \"json_label\"\\] \nquery \nHTTP Query \nExpand HTTP Query definition... \ndownload \nstring \nDefaults to false. If set to true, the HTTP response will have content-disposition and other headers set to make the HTTP response behave as a downloadable attachment instead of as inline content.\n\nResponse\n--------\n\n### 200: SQL Runner Query\n\nDatatype \nDescription \n(string) \nstring \n\n### 400: Bad Request\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 404: Not Found\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 422: Validation Error\n\nDatatype \nDescription \n(object) \n[ValidationError](/looker/docs/reference/looker-api/latest/types/ValidationError) \nmessage \n*lock* \nstring \nError details \nerrors \n[ValidationErrorDetail](/looker/docs/reference/looker-api/latest/types/ValidationErrorDetail)\\[\\] \nExpand ValidationErrorDetail definition... \nfield \n*lock* \nstring \nField with error \ncode \n*lock* \nstring \nError code \nmessage \n*lock* \nstring \nError info message \ndocumentation_url \n*lock* \nstring \nDocumentation link \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 429: Too Many Requests\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link"]]