Hello everybody,
I am working with JDBC connector, and faced an issue with a single account aggregation. The query for Single account is exactly the same as Account SQL Query, just added WHERE e.emp_id = '$(identity)'
. The query is working in SQL Studio if I substitute e.emp_id with an actual value, like:
WHERE e.emp_id = '777777'
I checked the logs, and thats what I am getting:
I will attach the whole sql query just in case:
SELECT e.emp_id, e.emp_login_nm, e.emp_title_id, e.emp_proc_grp_id, e.emp_sec_group_id, e.inactive_ind, e.emp_fname, e.emp_lname, e.emp_email, e.emp_phone, , e.emp_proc_id, e.emp_officer_id, e.appr_id, e.emp_officer_ind, e.emp_sys_user_yn, e.emp_new_user_yn, e.emp_external_yn, e.appr_g_role_type_id, e.emp_locale_id, e.emp_timezone_code, e.emp_deal_desicion_yn, e.emp_official_yn, case when e.inactive_ind IS NOT NULL then 'true' else 'false' end as IIQDisabled, t.pos_desc
,CASE WHEN emp_officer_id IS NOT NULL then 'isOfficer_Y'ELSE 'isOfficer_N' END AS isOfficer_YN, affs.lgl_ent_id, l2.lgl_ent_val, rl.code_desc, appr_rel.appr_g_id
FROM [emp] e
LEFT JOIN [sec_group] sg ON e.emp_sec_group_id = sg.secg_id
LEFT JOIN [legal_ent] l ON e.emp_lgl_ent_id = l.lgl_ent_id
LEFT JOIN internal_position t ON e.emp_title_id = t.pos_id
LEFT JOIN process_group p ON e.emp_proc_grp_id = p.proc_grp_id
LEFT JOIn emp_affiliate_rel affs ON e.emp_id = affs.emp_id
LEFT JOIN legal_ent l2 on affs.lgl_ent_id = l2.lgl_ent_id
LEFT JOIN code rl on e.appr_g_role_type_id = rl.code_id
LEFT JOIN emp_appr_rel appr_rel on e.emp_id = appr_rel.emp_id
LEFT JOIN approval_matrix a on appr_rel.appr_g_id = a.appr_id
WHERE e.emp_id = '$(identity)'
Please help, thanks in advance!