On 12/13/2018 1:58 PM, Joseph L. Casale wrote:
I have data that resembles the following:

Request           Number            Description
REQ0090887  TASK0236753  Foo
REQ0090887  TASK0234920  Bar
REQ0090887  TASK0234921  Bar
REQ0090887  TASK0237261  Foo
REQ0086880  TASK0224045  Foo
REQ0086903  TASK0224555  Bar
REQ0086990  TASK0223977  Bar
REQ0087061  TASK0226748  Foo
REQ0087061  TASK0223810  Bar

I want to group request values where each request contains both a
task with description Foo and Bar. So in the above example, only
REQ0090887 and REQ0087061 meet this.

select Request from MyTable group by Request having count(distinct Description) 
= 2

--
Igor Tandetnik

_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to