W3C home > Mailing lists > Public > public-html@w3.org > November 2007

SQL API -- named arguments

From: Jim Jewett <jimjjewett@gmail.com>
Date: Wed, 31 Oct 2007 23:40:46 -0400
Message-ID: <fb6fbf560710312040g503feb38u842e5b97a830c824@mail.gmail.com>
To: public-html@w3.org

The API supports only positional replacements, such as

"select a, b from mytable where c='?' and d>'?'", [4, 5]

Should there be some support for named replacements, like

"select a, b from mytable where c='?val1' and d>'?val2'",
{val1: 4, val2: 5}

Note that this works more easily if there is some sort of limit on
what can replace a '?', so that it is possible to take anything next
to it (until whitespace or punctuation) as a name, rather than a
literal.

-jJ
Received on Thursday, 1 November 2007 03:40:57 UTC

This archive was generated by hypermail 2.4.0 : Saturday, 9 October 2021 18:44:23 UTC