I would like to create a mailing list to send automatic emails. To do this I use the function below and here is the result, it doesn't work. Can you help me?
SELECT LISTAGG(Cf$_Email, ';') WITHIN GROUP (ORDER BY b.source_ref1) FROM customer_order_cfv a , SHIPMENT_LINE b where a.order_no= b.source_ref1 and b.shipment_id= :shipment_id
For information, it works in Apps10
Best answer by Marcel.Ausan
@Franck.G could you try to use square brackets and append & at the beggining of your select statement?
Below is an example that works for me:
[&select CF$_PROJECT_ID from customer_order_inv_head_cfv where invoice_id = '[@CUSTOMER_ORDER_IVC_REP/INVOICE_ID_STR]']
Additionally you could try to create a CF in the invoice entity to get the list of emails and then use it directly in the action properties, like you use regular fields.
@Franck.G could you try to use square brackets and append & at the beggining of your select statement?
Below is an example that works for me:
[&select CF$_PROJECT_ID from customer_order_inv_head_cfv where invoice_id = '[@CUSTOMER_ORDER_IVC_REP/INVOICE_ID_STR]']
Additionally you could try to create a CF in the invoice entity to get the list of emails and then use it directly in the action properties, like you use regular fields.
[&SELECT LISTAGG(EMAIL, CHR(59)) WITHIN GROUP (ORDER BY EMAIL) FROM CUSTOMER_INFO_CONTACT_LOV WHERE customer_id='[@CUSTOMER_ORDER_IVC_REP/CUSTOMER_NO]']