Trouble creating updatable BAQ for ability for sales reps to add customer visit notes


(Gregory Leepart) #1

Hello. I’ve created updatable BAQs in the past and been able to use them in a mobile (EWA) dashboard.

I am attempting to find a way for the sales reps to log visit notes for their customers. Reusing the CRMCall table seems like a great way to go. Unfortunately, there are some required fields (RelatedToFile [always ‘person’], Key1 [CustNum], and Key3). I’ve figured out how to get RelatedToFile to default to ‘person’, and Key3 can be blank.

What I’m left with is setting the value of Key1 to default to the Customer.CustNum. This column is already in the BAQ so I would think it would be easy to do but can’t seem to figure out the syntax to do so.

Any suggestions would be greatly appreciated. Thank you for your time in advance. I have attached a screenshot in case it can be of use to you.


(Jason Woods) #2

Try this: CONVERT(varchar(10), Customer_CustNum)


(Chris Conn) #3

Honestly I dont know what the difference in calls are, but you could also do a CAST(Customer_CustNum as varchar(10)) as well


(Gregory Leepart) #4

I totally get the CONVERT, CAST options. But it doesn’t seem to recognize the present data.

“The name Customer_CustNum does not exist in the current context”. If I could get it in there, I could play with it for sure.


(Jason Woods) #5

That is the field name without the table.
I believe you are looking for
ttResults.Customer_CustNum


(Gregory Leepart) #6

Tried that but it said it wasn’t present.

It’s not a part of the BO, but part of the baq query… So I’m guessing it needs to be part of the BO to be accessible.

Also guessing, probably using a BPM is the best route, but that’s 8 levels more complex than I’ve had exposure to. :frowning:

Greg