EXPAND ALL
- Home
- About Pixie
- Installing Pixie
- Using Pixie
- Tutorials
- Reference
Replaces constants with '$n' placeholders.Outputs the normalized query along with the values of the parameters
The normalized query with the values of the parameters in the query as JSON.
Variable | Type | Description |
---|---|---|
sql_string | STRING | The PostgresSQL query string |
cmd_code | STRING | The PostgresSQL command tag for this sql request. |
# Normalize the SQL query.df.normalized_sql_json = px.normalize_pgsql(df.sql_query_string)# Pluck the relevant values from the json.df.normed_query = px.pluck(df.normalized_sql_json, 'query')df.params = px.pluck(df.normalized_sql_json, 'params')