I have a query as follows:
select | ocrd.cardcode, OCRD.CardName, oins.insid, |
t0.DocEntry as 'MeterID', t0.U_mcode as 'MeterCode', t0.u_mr_type as 'MeterType', | |
t0.U_mr_value as 'MeterValue', t0.U_mr_date as 'MeterReadDate', t0.U_mr_credit as 'MeterCredit', | |
t0.U_billed as 'Billed?', U_remarks as 'Remarks' |
From [dbo].[UDT1] t0
inner join oins on oins.insid = t0.U_insID
inner join ocrd on OINS.customer = ocrd.CardCode
inner join ctr1 on oins.insid = ctr1.InsID
inner join octr on ctr1.ContractID = octr.ContractID
where t0.U_reset = 'Y' AND octr.owner = $[user]
ORDER BY ocrd.CardName
I'm wondering if this query will work in an alert. I want to return only the results for the person that the alert is showing up for. Is this a viable option?