Hi,
I have the below code from the SQL view of access:
SELECT
tblDealsTeamreport.[CIBR Deal ID],
tblSalesTeamreport.[Team Member Name],
tblDealsTeamreport.[Associate Name],
tblNamesCIBRtoSF.[SF Name]
FROM
(tblDealsTeamreport
INNER JOIN tblSalesTeamreport ON tblDealsTeamreport.[CIBR Deal ID] = tblSalesTeamreport.[CIBR Deal ID])
LEFT JOIN tblNamesCIBRtoSF ON tblDealsTeamreport.[Associate Name] = tblNamesCIBRtoSF.[CIBR Name]
What I'm getting though is a few blank (NULL) results in the [SF Name] column and this is because those names are not contained in tblNamesCIBRtoSF. What sort of IF statement could I write in order for when 'SF Name' is blank it selects the [Associate Name] instead and puts that in the [SF Name] column?
Any help or suggestions would be greatly appreciated.
I have the below code from the SQL view of access:
SELECT
tblDealsTeamreport.[CIBR Deal ID],
tblSalesTeamreport.[Team Member Name],
tblDealsTeamreport.[Associate Name],
tblNamesCIBRtoSF.[SF Name]
FROM
(tblDealsTeamreport
INNER JOIN tblSalesTeamreport ON tblDealsTeamreport.[CIBR Deal ID] = tblSalesTeamreport.[CIBR Deal ID])
LEFT JOIN tblNamesCIBRtoSF ON tblDealsTeamreport.[Associate Name] = tblNamesCIBRtoSF.[CIBR Name]
What I'm getting though is a few blank (NULL) results in the [SF Name] column and this is because those names are not contained in tblNamesCIBRtoSF. What sort of IF statement could I write in order for when 'SF Name' is blank it selects the [Associate Name] instead and puts that in the [SF Name] column?
Any help or suggestions would be greatly appreciated.