You are probably looking for something like
SQL Server:
((woclass = 'WORKORDER' or woclass = 'ACTIVITY') and historyflag = 0 and siteid = 'BEDFORD' and istask = 0 and pmnum is not null and targcompdate <= getdate() and worktype = 'PM')
Oracle:
((woclass = 'WORKORDER' or woclass = 'ACTIVITY') and historyflag = 0 and siteid = 'BEDFORD' and istask = 0 and pmnum is not null and targcompdate <= SSYDATE and worktype = 'PM')
The pmnum is not null is if you are looking for those generated from pm records; worktype = 'PM' is if you want to use the worktype as the filter, and since I was not sure what you wanted, I included both.