on 08-13-2018 12:43 PM
I'm learning SAP Business One and I need help with one thing:
Let's imagine I create a Purchase Order, and then I need to receive a A/P Downpayment Receipt from the vendor within 5 days. If I do not receive it within 5 days, I need to receive a notification/alert in SAP B1 to notify me about it and then I will request for it again by calling.
Question: How can I automate the notification/alert? Maybe with a query?
Hi,
That is correct, you would need to write a query to use with the alert system.
Regards,
Johan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Johan,
Thank you for your reply. Can you help me out with this query?
I tried this:
SELECT T0."DocNum" AS "Document Number", T0."CardCode" AS "Customer/Vendor Code", T0."DocDate" AS "Posting Date", T0."DocStatus" AS "Document Status" FROM "SBODEMORU"."OPOR" T0 WHERE T0."DocStatus" = ('O' ) AND T0."DocDate" = (ADD_DAYS(CURRENT_DATE, -5))
What else should I add?
Also, when I add this query to Alerts Management, I don't get a notification:
Frequency is 1 minute and in General Setting -> Services -> Update Messages = 0 min
What's the problem?
Hi,
My system version does not have A/P Down Payment Request, so I cannot give you a precise answer.
Please have a look in the B1 client at a purchase order that has an A/P Down Payment Request linked to it. Check the A/P Down Payment Request to see what the table is. The link is probably in that table.
Regards,
Johan
Johan,
Maybe something's wrong with the query.
Question: User creates a PO, he needs to receive a notification if GRPO is not created within 5 days.
How to do this?
Hi Shak,
This appears to be HANA syntax, and unfortunately I am not familiar with its functions. Does CURRENT_DATE return a date and time like GETDATE() ? If so, the parameter T0."DocDate" = (ADD_DAYS(CURRENT_DATE, -5)) can only ever be true at 00:00:00 o'clock. You can catch this by using >=
Otherwise I do not really see anything wrong with your query. You can also try to not use field aliases. It is not impossible that the alert system somehow needs the original field names. I would also recommend using DocDueDate instead of DocDate.
So could you please test this:
SELECT T0."DocNum"
, T0."CardCode"
, T0."DocDate"
, T0."DocStatus"
FROM "SBODEMORU"."OPOR" T0
WHERE T0."DocStatus" = ('O' )
AND T0."DocDueDate" >= (ADD_DAYS(CURRENT_DATE, -5))
Regards,
Johan
Hi Shak,
The DocStatus of a purchase order that is linked to a Goods Receipt PO, will be 'C', and thus will will no longer be returned by your query.
Regards,
Johan
Please mark helpful answer and close this thread
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
99 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.