0

i'm Using subsonic 2.0 and i need to execute the below query

Select * from User where User ID = 1 and (Status = 2 Or Status = 3)

Your help will be highly appreciated.

Allam
  • 9
  • 1
  • 4

1 Answers1

0

This is how I did it using and In statement:

Select * from User Where UserID = 1 And Status In (2,3)

TblUserCollection vacReqColl = new Select().From(TblUser.Schema).Where(TblUser.Columns.UserI).IsEqualTo(userID).                    And(TblUser.Columns.Status).In(Status1, Status2).OrderAsc(new string[] { "CreationDate" }).ExecuteAsCollection<TblUserCollection>();
Undo
  • 25,519
  • 37
  • 106
  • 129
Allam
  • 9
  • 1
  • 4