graphql-engine/server/lib
Samir Talwar 15ac52ded4 server: Fix the Analyze feature for SQL Server.
The "Analyze" feature for SQL Server only partially worked. It would show the SQL generated, but not the execution plan. This is because SQL Server doesn't support generating a plan for prepared statements with parameters.

To work around this, we restructure the query as one without parameters. Instead, we replace each parameter with a variable. We declare the variables but don't set values. We then plan _that_, which works.

We run all this in a single query because local variables only last for a single transaction/batch.

This feature does not work for stored procedures.

[NDAT-582]: https://hasurahq.atlassian.net/browse/NDAT-582?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10125
GitOrigin-RevId: a4b45b9b207456ff4fbd1b69b008e93f87346342
2023-08-17 12:51:57 +00:00
..
aeson-ordered Upgrade Ormolu to 0.7.0.0 2023-05-24 13:53:53 +00:00
api-tests server: Fix the Analyze feature for SQL Server. 2023-08-17 12:51:57 +00:00
arrows-extra Move query validation into the schema cache building code 2023-06-12 14:57:41 +00:00
ci-info chore(ci-info): fix various compiler warnings 2023-06-08 12:25:22 +00:00
dc-api Data Connectors Native Queries Support 2023-08-17 02:05:14 +00:00
ekg-json chore(tooling): import ekg-json into the monorepo 2023-06-07 08:38:48 +00:00
ekg-prometheus chore(tooling): import ekg-prometheus into the monorepo 2023-06-27 18:37:11 +00:00
graphql-parser server: Remove Weeder. 2023-08-08 10:39:27 +00:00
hasura-base server: add support for header resolution from env vars 2023-06-23 08:39:28 +00:00
hasura-error-message server: Rename "error-message" to "hasura-error-message". 2023-06-27 16:51:06 +00:00
hasura-extras Nested where 2023-08-01 05:41:36 +00:00
hasura-json-encoding Put the message property first when encoding error JSON 2023-06-02 05:29:50 +00:00
hasura-prelude Upgrade Ormolu to 0.7.0.0 2023-05-24 13:53:53 +00:00
incremental server: Upgrade the HGE server to GHC 9.4.5 2023-06-06 13:29:30 +00:00
pg-client server: add Prometheus metrics hasura_postgres_connection_init_time and hasura_postgres_pool_wait_time 2023-08-10 11:08:42 +00:00
resource-pool Upgrade Ormolu to 0.7.0.0 2023-05-24 13:53:53 +00:00
schema-parsers server: fix issue with remote schema customisation & null values 2023-08-10 06:42:36 +00:00
test-harness server: Fix the Analyze feature for SQL Server. 2023-08-17 12:51:57 +00:00
upgrade-tests Log Postgres Source Names in Connection Errors 2023-07-20 11:20:09 +00:00