Hi All,
I'm having problems with the following code, my results are bringing back more than 1 a.vin_refno per a.vin_pro_refno
any ideas?
many thanks
Sam
SELECT a.vin_pro_refno, MAX (a.vin_refno), vin.vin_hrv_vcl_code,
vin.vin_vpa_curr_code
FROM void_instances a, void_instances vin, hou_prop_statuses
WHERE a.vin_refno = vin.vin_refno
and vin.vin_pro_refno = hps_pro_refno
and hps_hpc_code = 'VOID'
and hps_end_date is null
GROUP BY a.vin_pro_refno, vin.vin_hrv_vcl_code, vin.vin_vpa_curr_code
I'm having problems with the following code, my results are bringing back more than 1 a.vin_refno per a.vin_pro_refno
any ideas?
many thanks
Sam
SELECT a.vin_pro_refno, MAX (a.vin_refno), vin.vin_hrv_vcl_code,
vin.vin_vpa_curr_code
FROM void_instances a, void_instances vin, hou_prop_statuses
WHERE a.vin_refno = vin.vin_refno
and vin.vin_pro_refno = hps_pro_refno
and hps_hpc_code = 'VOID'
and hps_end_date is null
GROUP BY a.vin_pro_refno, vin.vin_hrv_vcl_code, vin.vin_vpa_curr_code