Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

[Feature] Set parameters as key-value pairs and pass parameters to the sql. #97

Open
zsong opened this Issue · 2 comments

3 participants

Ziang Song Jonathan Guerin Evgen Domnenko
Ziang Song

Suppose the sql query starts with something like this

declare @A varchar(100)
declare @B varchar(100)

to properly assign the properties, we need the variable names defined in the params like this:

sql.query(conn_str, sqlquery, [ {"A": "vauleA"}, {'B', "valueB"} ], call_back);

Or something similar to that.

Jonathan Guerin

Thanks for the suggestion, we'll evaluate it for our next version :)

Evgen Domnenko

Great suggestion but next syntax sql.query(conn_str, sqlquery, {"A": "vauleA", "B": "valueB"}, call_back); (without array notation, just JSON object with keys - as parameter names and values as param values) will be better IMHO

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.