Open alexwijoyo opened 2 months ago
This is an example provided by the third-party library the illa-builder is using: https://github.com/microsoft/go-mssqldb?tab=readme-ov-file#parameters. The ?
is not supported as a parameter placeholder.
@naj1n the problem is because illa-builder send the query using positional ? parameter placeholder not named parameter such as @p1. Please read my step 5 & 6. That a trace from sql server profiler.
According to the code comments at https://github.com/illacloud/builder-backend/blob/8664551df998df0fe2711b51d6ef8e439fa8b2d5/src/utils/parser/sql/escaper.go#L371, changes need to be made in the way SQL is written.
@naj1n ,
How should I rewrite my sql:
select der.* from DailyExchangeRate der where der.SrcCurrencyId<>'USD' and Date between '{{dtrDer.value[0]}}' and '{{dtrDer.value[1]}}'
@naj1n , Any progress about this?
I will try to run some tests and will update here with any progress.
Description
When I run query using safe SQL parameter, I got Incorrect syntax near '?'.
Steps to reproduce
Version
self-host
ILLA Builder Version
latest
Browser
No response
Operating System
Additional Information
No response