Focal Point
SOLVED - Finding Unmatched Records

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/619105002

August 05, 2009, 11:42 AM
<Mary3001>
SOLVED - Finding Unmatched Records
I am writing a report that shows what new branches were open between the prior year end and the current ytd file. The process in Access was to join the two tables by br_id and then filter on br_id in the prior year as null. I have not had any success in WebFocus using this process. Is there a way to either write a define (and where should it be placed, before or after the join) or a where/if statement that will show records contained in the ytd file that are not in the prior year table. I'm a beginner and don't use sql much, so I need a process using the gui screens. I have tried joins all ways (unspecified, inner, outer) and also changing the table join order, several defines with moving the defines before and after the join when the define didn't work and where/ifs and nothing works.

I'm using Developer Studio 7.61 in the managed reporting area.

Thanks so much.

This message has been edited. Last edited by: <Mary3001>,
August 05, 2009, 12:02 PM
Darin Lee
There are a couple of different ways to do it.

I don't know if you are familiar with MATCH logic or not. It is available in the GUI and fully described in the documentation. Using this you could use a NEW-NOT-OLD comparision.

Using the same methodology as you describe, you could also do it with a JOIN.

You would need to SET ALL=ON which allows you to do a left outer join. Then
JOIN BR_ID IN CURRYR TO BR_ID IN PRIORYR AS JOIN1
TABLE FILE CURRYR
PRINT BR_ID
WHERE PRIORYR.BR_ID EQ MISSING;
END


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
August 05, 2009, 01:52 PM
<Mary3001>
Darin, thanks so much. I am using the Match feature. I had searching Help for "unmatched records" which is why I didn't find the solution. This solution works great and I can also use it for my closed branches report.

I also did try using join as you have it written and it was not working. Perhaps that is a server issue as when I previously tried to create a parameter report and was not able to, our WebFocus IT team had to turn "auto prompting" to "on" on our reporting server.

Thanks so much for your great help!