BAQ Sales Rep


I am currently working on creating a dashboard for people to check sales order related information. I wrote the BAQ and created the dashboard in our TEST environment. There’s no issue was found there. However, when they imported my dashboard from TEST into PROD, there is a missing customer was found on the dashboard. I have checked the BAQ in PROD and found out if I deleted the sales rep table, the missing customer will return after I analyze my BAQ. I am wondering what could go wrong? The BAQ returned the same customer in TEST but not in PROD.

Here’s the BAQ I create in TEST and customer #2325701 did return

In PROD, the BAQ returns 0 row when I am searching for the same customer:

When I delete the Sales Rep table, the same customer will appear.

Thank you,

Does the customer have a sales rep selected? Do you have an ourter or inner join between customer and sales rep?

What is the Criteria on your Sales Rep Table? An outer join to a table with criteria can be an issue.

The customer don’t have a sales rep selected. I have an left ourter join between the two.

Your criteria on the SalesRep table needs to allow for this such as
(what your criteria is)

Hi Patrick,

The Criteria on the Sales Rep Table is just a search I created.

My thoughts on doing a outer join is we have few customers who don’t have any sales rep assigned to.

Delete the criteria and see if the missing record appears.
Then you will confirm this is the issue.
If this is the case.
Add your criterial back in, then add a second line (or Name = Null).
Make sure it’s “or” not “and”.

Let me make sure I understand this. How do I do “And Null”. Do you mean by SalesRepCode ISNULL?

This seems to cause all my sales rep is null.

I will give it s shot. Thank you, Patrick!

I have tried to delete the criteria, the missing record didn’t appear. Then I add a second line Name = Null with “or”, the record is still missing. But when I try to delete the whole table, the record comes back. The links between two tables are company = company, sales rep code = sales rep code. Do you think the link could be wrong?

Thank you for your help.

If the record doesn’t show with the criteria removed.
Then something else is going on.
Add the table back and test for the record disappearing after every change until you track in down.

1 Like

Any calculated fields in your report? If so, remember to check their formulas if they have links against them. Might need null checks and or other checks there as well.

Turns out the parameters is throwing me off. I forget to check ‘Skip condition if empty’ on Sales Rep Parameters.

Now I have checked this checkbox, the missing record appears on my BAQ.

Thank you so much for everyone’s help!

Good find, well done.

1 Like