querying data question

Hi,

I have some data in a table

Apr 30, 2020 @ 00:00:00.000	John Doe	169c341e6794470aac9669a5dc5c691b	code306	1
Apr 30, 2020 @ 00:00:00.000	John Doe	169c341e6794470aac9669a5dc5c691b	code120	1
Apr 30, 2020 @ 00:00:00.000	John Doe	ce20c00d07b187efda72165419bcfc40	code120	1
Apr 29, 2020 @ 00:00:00.000	John Doe	169c341e6794470aac9669a5dc5c691b	code306	1


and *want to find which name (John Doe) has an occurence of code 306 and code 120 on the same day. My data is ordered by the date column. How do I get what I need?

Thank you!

There are several different ways to solve this problem. The attached file shows two of them - using the formula for the case when the data is presented exactly in the form that you showed in your question, each log record in one string, and using the pivot table for the case when the data is divided into separate columns - Find a pair.ods

I actually ended up importing the csv data into a sqlite table and put together a query to extract my data accordingly.