Selection for primary insurance names secondary same name in SQL
I am recreating a report from another program into our SQL database. This report is looking for all patients based on facility that were discharged on a certain date that had ESSENCE as their primary insurance and Admit and Primary Care phy are restricted. It should also list their secondary and tertiary insurance as well.
When I run this report in theSQL database program I get the correct patient name but lists the primary insurance (essence) twice InsuranceSeqOrderID of 1 for both BUT the Policy numbers are different???
Please see below.
RESULTS:: Due to patient confientiality, I will only show conflicting fields: