---> This is data insert without Com_id
---> Create Interactive Report Query :
select ID,
TYPE,
NAME,
decode(STATUS,1,'Active',0, 'Deactive')STATUS,
get_company_dtl('N',COM_ID) COMPANY,
CREATE_BY,
CREATE_DATE,
UPDATE_BY,
UPDATE_DATE,
CODE,
case when COM_ID is not null then
'<div style="margin-bottom: 10px; text-align: center" >
<a href="'||apex_util.prepare_url('f? p='||:APP_ID||':'||10||':'||:APP_SESSION||'::::P10_ID:'||id) || '"
style="color:green;
background:white;
margin: 3px;
-- border: 2px solid;
-- border-radius: 15px;
padding-top: 5px;
padding-right: 25px;
padding-bottom: 5px;
padding-left: 15px;
"> <span aria-label="Edit"><span class="fa fa-edit" aria-hidden="true" title="Edit"></span></span> </a> </div>'
else
'<span class="fa fa-lock-check" aria-hidden="true"></span>' end Edit
From LOOKUP_DATA
WHERE COM_ID=:GCOM_ID
AND TYPE ='STAKEHOLDER REFERENCE TYPE'
OR ID IN (SELECT ID FROM LOOKUP_DATA WHERE TYPE ='STAKEHOLDER REFERENCE TYPE' and COM_ID IS NULL)
-- ORDER BY 1 ASC