Hello, I contact with the community because I need to include in my sql query an OBS filter.
We have defined a OBS that contain the organizational structure. The name of this field, in project's objetc is "OBS Ejecucion", and this field use the browse " OBS_BROWSE_FLT_PRJ". I need to filter for one of this structure.
The query in SQL looks like this:
Select COUNT(*) AS CANTIDAD, lookup.NAME as Tipo
from niku.INV_INVESTMENTS as inv
inner join niku.ODF_CA_INV as ca on inv.ID=ca.ID
inner join niku.ODF_CA_PROJECT as prj on inv.ID=prj.ID
inner join niku.CMN_LOOKUPS_V as lookup on obj_request_type=lookup.LOOKUP_CODE
where inv.IS_ACTIVE=1
and lookup.LOOKUP_TYPE= 'OBJ_IDEA_PROJECT_TYPE' and lookup.LANGUAGE_CODE='es'
and (obj_request_type = 'type100' or obj_request_type = 'type200' or obj_request_type = 'type300') --Oro / Plata / Bonce--
and (osde_res_sol_cc = '01') -- Alta Aprobada
and (HOW TO FILTER BY OBS)????? = '' /OSDE Binario/Dirección de Procesos y Sistemas/Gerencia de Soluciones de Negocio"
group by lookup.NAME
Anyone can help me with this query?
Regards.
Patricio.