Converting SQL Query to use in View

 Hi Experts,

 I have a requirement to show the list of incidents which has opened before 7 days with respect to logical name in View/Favourites.

 So I have written a query in SQL.

 select NUMBER, LOGICAL_NAME  from PROBSUMMARYM1 where  OPEN_TIME>='2018-03-10' and LOGICAL_NAME in (select LOGICAL_NAME from PROBSUMMARYM1) order by LOGICAL_NAME

 I need the equivalent query to do it in View.

 i know OPEN_TIME>='XXXXXXXX'  this can be written like this    open.time>=date(tod()) - '7 00:00:00', but not sure how to do the inner query.

 Any Suggestions are appreciated. Thank You.