Skip to content

Instantly share code, notes, and snippets.

@johnzablocki
Created September 4, 2012 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save johnzablocki/3621597 to your computer and use it in GitHub Desktop.
Save johnzablocki/3621597 to your computer and use it in GitHub Desktop.
Couchbase .NET Client Library Doc Insert and View Query
var newBeer = new Beer { Name = "Atlantic Amber" };
client.StoreJson(StoreMode.Add, "beer_Atlantic_Amber", newBeer);
var view = client.GetView<Beer>("beers", "by_name")
foreach(var beer in view.Key("Atlantic Amber").Limit(1))
{
Console.WriteLine(beer.Name);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment