Hello all.
I have two tables that I have joined and I am having an issue if the Reg E Dispute Data table CompCode column is blank. The Close Code in tbl_ADH Close Codes table is joined to the CompCode in the Reg E Dispute Data table. I want the description in the Code Description column to reflect if the Closed Code and the CompCode fields are blank. How does one accomplish that? I hope that made sense.
Here is my sql. Thanks for your help.
SELECT [Reg E Dispute Data].CaseID, [Reg E Dispute Data].DateOpened, [Reg E Dispute Data].ClaimAmount, [Reg E Dispute Data].Type, [Reg E Dispute Data].PaymentChannel, [Reg E Dispute Data].DateClosed, [tbl_ADH Close Codes].[Code Description]
FROM [Reg E Dispute Data] LEFT JOIN [tbl_ADH Close Codes] ON [Reg E Dispute Data].CompCode = [tbl_ADH Close Codes].[Close Code]
WHERE ((([Reg E Dispute Data].DateOpened) Between [Start Date] And [End Date]) AND (([Reg E Dispute Data].Type)="DS" Or ([Reg E Dispute Data].Type)="FR") AND (([Reg E Dispute Data].PaymentChannel) Like [Enter Payment Channel] & "*"));
I have two tables that I have joined and I am having an issue if the Reg E Dispute Data table CompCode column is blank. The Close Code in tbl_ADH Close Codes table is joined to the CompCode in the Reg E Dispute Data table. I want the description in the Code Description column to reflect if the Closed Code and the CompCode fields are blank. How does one accomplish that? I hope that made sense.
Here is my sql. Thanks for your help.
SELECT [Reg E Dispute Data].CaseID, [Reg E Dispute Data].DateOpened, [Reg E Dispute Data].ClaimAmount, [Reg E Dispute Data].Type, [Reg E Dispute Data].PaymentChannel, [Reg E Dispute Data].DateClosed, [tbl_ADH Close Codes].[Code Description]
FROM [Reg E Dispute Data] LEFT JOIN [tbl_ADH Close Codes] ON [Reg E Dispute Data].CompCode = [tbl_ADH Close Codes].[Close Code]
WHERE ((([Reg E Dispute Data].DateOpened) Between [Start Date] And [End Date]) AND (([Reg E Dispute Data].Type)="DS" Or ([Reg E Dispute Data].Type)="FR") AND (([Reg E Dispute Data].PaymentChannel) Like [Enter Payment Channel] & "*"));