Skip to content

Instantly share code, notes, and snippets.

@jeffrymorris
Created May 27, 2015 17:11
Show Gist options
  • Save jeffrymorris/58352af7e2052a9f72cd to your computer and use it in GitHub Desktop.
Save jeffrymorris/58352af7e2052a9f72cd to your computer and use it in GitHub Desktop.
Positional parameters
using (var bucket = _cluster.OpenBucket())
{
var queryRequest = new QueryRequest()
.Statement("SELECT * FROM `beer-sample` LIMIT $1")
.AddPositionalParameter(10);
var result = await bucket.QueryAsync<dynamic>(queryRequest);
Assert.IsTrue(result.Success);
Assert.AreEqual(10, result.Rows.Count);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment