RE: SELECT Command - For beginner.



use northwind

select orderid,customerid,employeeid from orders
where customerid='vinet' and employeeid=5

group by customerid,employeeid,orderid
having count(*) = 1

--
Jose de Jesus Jr. Mcp,Mcdba
Data Architect
Sykes Asia (Manila philippines)
MCP #2324787


"Ben" wrote:

> Hi, I am having a problem with a SELECT Command.
>
> I am wanting to search unique queries from TableA where Field1 = "specific
> Criteria" and Field2 = "Another Specific Criteria.
>
> The string that I have is as follows:
>
> SELECT DISTINCT * FROM Table WHERE fld1 = 'opt1' AND WHERE fld2 = 'opt2';
>
> Any help is appreciated. As you see I am still very new to SQL queries
>
>
>
.



Relevant Pages

  • RE: Create table rights
    ... i think the user is be a member of a denied group ... Jose de Jesus Jr. ... Sykes Asia ...
    (microsoft.public.sqlserver.security)
  • RE: Users and Truncate Table
    ... Jose de Jesus Jr. ... MCP #2324787 ... >> Sykes Asia (Manila philippines) ...
    (microsoft.public.sqlserver.security)
  • Re: Bubba Betrays the Troops
    ... >>> That would be 'Resistance to change' again. ... >>> Jesus the researchers could have saved their time and just ... Maybe you and Jose No Se should join up and form Johnnie and Jose ... You only continue to spin your own blather and idiocy! ...
    (alt.politics.bush)
  • Re: is there a better way to do this???
    ... Any arbitrary row may be returned. ... "jose g. de jesus jr mcp, mcdba" <jose g. de jesus jr mcp, ...
    (microsoft.public.sqlserver.programming)
  • opening port 1433 to the web
    ... Jose de Jesus Jr. ... Sykes Asia (Manila philippines) ... MCP #2324787 ...
    (microsoft.public.sqlserver.security)