MS ACCESS query
- From: "Dave Harrington" <dharrington@xxxxxxxxxxxxxxxx>
- Date: Mon, 5 Dec 2005 14:55:41 -0500
Hi all -
I got a pretty basic question that's been bugging me today. I'm using
ASP.NET, C# and MS Access for a database driven application. I have a
datagrid that will populate based on a registered user's access level.
There are some instances where I'd like to use a basic OR statement in my
Access query, but I do not know the syntax. The statement I'd like to use
is below
cmd = new OleDbCommand("Select * FROM
"+Session["ClassroomSession"].ToString()+"WHERE AccessLevel=\"All\" OR
AccessLevel=\"Speaker\" ORDER BY ID", conn);
In this case, I'd like to populate the datagrid with all elements WHERE the
field "AccessLevel" is EITHER "All" OR "Speaker".
Please help!
Thanks in advance.
Dave Harrington
.
- Follow-Ups:
- Re: MS ACCESS query
- From: Paul Clement
- Re: MS ACCESS query
- Prev by Date: Re: Page works fine with internal webserver but not on IIS
- Next by Date: Re: Interact with secundairy form.
- Previous by thread: HttpContext.RewritePath Broken in 2.0 Final Relase
- Next by thread: Re: MS ACCESS query
- Index(es):
Relevant Pages
|