How do I use the SQL WHERE IN construct with PetaPoco?
I have a database table named Tags (Id, Name) from which I would like to select the ones where the name matches a name in a list. In SQL I would use something like: Select * from Tags Where Name In ('Name1', 'Name2', 'xxx...) But now using PetaPoco in an ASP.Net MVC3 project I'm stuck figuring out how to do it properly. So far I've tried: var tagsToFind = new string[] { "SqlServer", "IIS" }; var sql = PetaPoco.Sql.Builder.Select("*").From("Tags").Where("Name in (@0)", tagsToFind); var result = db.Query<Tag>(sql); Which results in the following SQL, where only the first name in my list of