Repository Queries

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 14

There is a wealth of information to be found in the Informatica PowerCenter tables, which are accessed through views provided by Informatica.

At IU, all of these views are found in the INFORMATICA schema in DSS1PRD, DSS1TST, and DSS1DEV. Explanation of some fields:

SUBJECT_AREA - this is equivalent to the folder name.

Object queries:

Mapping names Source names Target names Lookup transformations: Tables used Lookup transformations: SQL Override text Source Qualifiers: SQL Query text from Session: SQL Query text from the source settings Workflow task and session names

Execution queries:

Session runs Workflow runs Runs of BRTE scripts which load data from workflows

For any of the queries which have 'search_string', replace it with the text for which you are looking. We also have included some of the Valid Values for some columns.
List mappings used in any workflow

(For more information, see the Informatica KB Document ID# 104897.) The following query will returns all mappings used in any workflow with associated folders, workflows, and sessions listed:
SELECT c.subject_area folder_name, a.task_name workflow_name, b.instance_name session_name, c.mapping_name FROM informatica.REP_ALL_TASKS a, informatica.REP_TASK_INST b, informatica.REP_LOAD_SESSIONS c WHERE a.subject_id=c.subject_id AND a.task_type=71 AND a.task_id=b.workflow_id AND b.task_type=68 AND b.task_id=c.session_id AND c.MAPPING_ID <> 0

ORDER BY 1,2,3,4

Other information:

The REP_LOAD_SESSIONS view contains both mapping and session object information. In both REP_ALL_TASKS and REP_TASK_INST, task_type for the workflow object is 71 and that for session is 68.

Source names

select s.SUBJECT_AREA as FOLDER_NAME, s.SOURCE_NAME, s.PARENT_SOURCE_DATABASE_TYPE, s.SOURCE_DATABASE_NAME from informatica.REP_ALL_SOURCES s where s.SOURCE_NAME like '%search_string%' order by 1,2
Target names

select t.SUBJECT_AREA as FOLDER_NAME, t.TARGET_NAME, t.PARENT_TARGET_DATABASE_TYPE from informatica.REP_ALL_TARGETS t where t.TARGET_NAME like '%search_string%' order by 1,2
Tables used in Lookup transformations

SELECT ram.PARENT_SUBJECT_AREA as FOLDER_NAME, ram.MAPPING_NAME, rwi.INSTANCE_NAME as TRANSFORMATION, rwa.ATTR_VALUE as LOOKUP_TABLE_NAME FROM informatica.REP_WIDGET_INST rwi, informatica.REP_ALL_MAPPINGS ram, informatica.REP_WIDGET_ATTR rwa WHERE rwi.MAPPING_ID = ram.MAPPING_ID AND rwi.WIDGET_ID = rwa.WIDGET_ID AND (rwa.ATTR_DESCRIPTION LIKE 'Lookup source table') order by 1, 2, 3, 4
Generate a list of SQL Overrides from Lookups

(For more information, see the Informatica KB Document ID# 23165.) This SQL will give you information about text entered in SQL Overrides within mapping lookups for a particular folder:
SELECT ram.PARENT_SUBJECT_AREA, ram.mapping_name, rwa.attr_name, rwa.attr_value FROM informatica.rep_widget_attr rwa, informatica.rep_all_mappings ram, (SELECT subject_id FROM informatica.rep_subject WHERE subject_area = 'foldername' ) x WHERE rwa.attr_name like '%Sql Override' AND ram.MAPPING_ID = rwa.mapping_id AND ram.subject_id = x.subject_id

Replace 'foldername' with the particular folder you want to search. Rather than search a particular folder, you could change the WHERE clause to exclude those folders you don't want to search:
WHERE subject_area != 'PS8_FA'

Or leave the 'WHERE subject_area ...' clause out completely to query all folders. If you want to look for a particular string within the SQL Override text, add a line to the very end of the query:
and rwa.ATTR_VALUE like '%search_string%'

Replace 'search_string' with the text you are looking for within the SQL Override.
SQL Query text from Source Qualifiers

select m.SUBJECT_AREA, m.MAPPING_NAME, a.LINE_NO, a.ATTR_NAME, a.ATTR_VALUE from informatica.REP_WIDGET_ATTR a, informatica.REP_WIDGET_INST i, informatica.REP_ALL_MAPPINGS m where a.WIDGET_ID = i.WIDGET_ID and i.MAPPING_ID = m.MAPPING_ID and a.WIDGET_TYPE = '3' and a.ATTR_ID = '1' order by m.SUBJECT_AREA, m.MAPPING_NAME, a.LINE_NO
SQL Query text from the source settings in a Session

(Note from Tina: when I was developing this query, I found it takes quite a while to run (like 6-7 minutes). I don't have time right now to figure out how to speed it up.)
select c.SUBJECT_AREA as FOLDER_NAME, a.TASK_NAME as WORKFLOW_NAME, b.INSTANCE_NAME as SESSION_NAME, w.PARTITION_ID, w.LINE_NO, w.ATTR_VALUE from informatica.OPB_SWIDGET_ATTR w, informatica.REP_ALL_TASKS a, informatica.REP_TASK_INST b, informatica.REP_LOAD_SESSIONS c where w.SESSION_ID = c.SESSION_ID and w.SESSION_ID = b.TASK_ID AND a.task_id=b.workflow_id and w.ATTR_ID = 1 AND a.task_type=71 and w.ATTR_VALUE like '%search_string%' order by c.SUBJECT_AREA, a.TASK_NAME, b.INSTANCE_NAME, w.PARTITION_ID, w.LINE_NO
Workflow task and session names

SELECT w.SUBJECT_AREA as FOLDER_NAME, w.WORKFLOW_NAME, c.TASK_TYPE, c.TASK_TYPE_NAME, c.INSTANCE_NAME AS TASK_NAME FROM informatica.REP_TASK_INST c, informatica.REP_WORKFLOWS w

WHERE c.WORKFLOW_ID = w.WORKFLOW_ID and c.TASK_TYPE != 62 --Excludes 'Start' task types and c.INSTANCE_NAME like '%search_string%' order by 1,2,4,5

Replace 'search_string' with the text you are looking for within the Workflow task and session names. Or remove that whole line from the query to get all task and session names.

Execution Queries For the following three queries, change the first WHERE clause line to change the time period you are looking for.
Number of sessions run in a given period of time

select count(*) from informatica.rep_task_inst_run r where r.START_TIME between to_date('09/21/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and to_date('09/22/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and TASK_TYPE = 68 and RUN_STATUS_CODE = 1
Number of workflows run in a given period of time

select count(*) from informatica.REP_WFLOW_RUN where START_TIME between to_date('09/21/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and to_date('09/22/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and RUN_STATUS_CODE = 1
List of command tasks which might run BRTE scripts which load data

select SUBJECT_AREA, WORKFLOW_NAME, TASK_NAME from informatica.rep_task_inst_run r where r.START_TIME between to_date('09/21/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and to_date('09/22/2010 00:00:00','MM/DD/YYYY HH24:MI:SS') and TASK_TYPE = 58 and RUN_STATUS_CODE = 1 and (TASK_NAME like '%brte%' or TASK_NAME like 'cmd_run%' or TASK_NAME like 'cmd_dss%' or TASK_NAME like 'cmd_build%') and TASK_NAME not like 'cmd_monitor%' and TASK_NAME not like 'cmd_touch%' and TASK_NAME not like '%done' and TASK_NAME not like '%donefile' and TASK_NAME not like '%indexes%' order by 3

The list is based on the names of the commands tasks. Since naming standards for command tasks aren't used consistently, it is possible this list isn't perfect. To get a more

accurate list, you might need to query the commands run in the command tasks and figure out which ones use scripts in dssprdb/batch or something like that.

Valid Values
Some RUN_STATUS_CODE values:

1 - Succeeded 2 - Disabled 3 - Failed 4 - Stopped 5 - Aborted 6 - Running 15 - Terminated

Some TASK_TYPE values:

58 - Command task 59 - Decision task 60 - Event Wait 61 - Event Raise 62 - "Start" task 65 - Email task 66 - Timer task 67 - Assignment task 68 - Session 70 - Worklet 71 - workflow 91 - Control task

Some WIDGET_TYPE values:

WIDGET_TYPE identifies a source, target, or transformation.)


3 - Source Qualifier 4 - Update strategy transformation 7 - Sequence generator 9 - Aggregator transformation 11 - Lookup transformation 12 - Joiner transformation 26 - Rank transformation 80 - Sorter transformation

Identifying Informatica PowerCenter sessions for tuning

1. The IUIE report "Informatica Sessions > 20 Min" (DSS_LOADS_OVER_20) will show you all sessions which took longer than 20 minutes today, how many rows it loaded, as well as the average/minimum/maximum run times and rows loaded. It is a good first step at identifying a process which may be holding up a particular DSS schedule. Rows highlighted in orange indicate a significant increase over the average. 2. The IUIE report "Informatica Daily Report (DSS_WF_RPT) can also give you information about a particular table load. Once you run the report for today's date, find the specific folder, workflow, then mapping you are interested in. On that line youll find the table name linked to another report which will list the runs for the past 90 days. The DSS_WF_RPT report output is pretty long, so using the table of contents can help you navigate more quickly to the correct folder. 3. The following is some SQL you can run against DSS1PRD. It will show you what the run times where for a particular table as far back as the information goes. If you want to look it up by session_name instead of table_name, use the line commented out instead.
4. select 5. t.SUBJECT_AREA as SUBJECT, t.WORKFLOW_NAME, t.SESSION_NAME, t.TABLE_NAME, 6. to_char(f.START_TIME,'YYYY-MM-DD') as RUN_DATE, f.MINUTES_SESS, f.SUCCESSFUL_AFFECTED_ROWS, f.THROUGHPUT 7. from dss.dss_inf_log_ft f, 8. dss.dss_tbl_sess_wf_dm t 9. where f.tbl_sess_wf_key=t.tbl_sess_wf_key 10. --and t.SESSION_NAME = '<session_name>' 11. and TABLE_NAME = '<table_name>' 12. order by f.START_TIME

13. Likewise, the following 3 tables will allow you to build a query to compare load time long term in test and production dss environments.
14. 15. 16. 17. 18. 19. 20. from dss.dss_inf_log_ft f, dss.dss_tbl_sess_wf_dm t, dss.dss_date_dm d

where f.date_key = d.date_key and f.tbl_sess_wf_key=t.tbl_sess_wf_key

Results go back to November 2004.

Oracle AWR reports These reports will show how a database is doing. It includes top resource consuming SQL and other stats that might be useful in looking into improving performance in your database application.

Using partitioning to speed up an Informatica job

At what step in the process should you rebuild indexes on a table? Typical full rebuild of a table with indexes: 1. 2. 3. 4. Drop indexes Truncate table Load data into table Rebuild indexes

If you fully rebuild a table and then do additional updates to the table: 1. 2. 3. 4. 5. Drop indexes Truncate table Load data into table Rebuild indexes Perform updates

The updates generally will occur a lot faster with the indexes on the table than without.

Space Utilization SQL to find tables in the DSS_MOVE01 tablespace over 100MB (outside the batch schedule)
SELECT A.OWNER "Owner", A.SEGMENT_NAME "Object name", A.SEGMENT_TYPE "Type", TO_CHAR(B.CREATED,'MM/DD/YY') "Created", TO_CHAR(B.LAST_DDL_TIME,'MM/DD/YY') "Last DDL", TO_CHAR((A.BYTES/1024/1024),'9,999') "MB" FROM DBA_SEGMENTS A, DBA_OBJECTS B WHERE A.TABLESPACE_NAME = 'DSS_MOVE01' AND A.SEGMENT_NAME = B.OBJECT_NAME AND A.SEGMENT_TYPE = B.OBJECT_TYPE AND A.OWNER = B.OWNER and (A.BYTES/1024/1024) >= 100 ORDER BY 6 desc

How to find all the mappings and sessions which have PARALLEL hints in the SQL Override
SELECT S.SUBJ_NAME, M.MAPPING_NAME, W.WIDGET_NAME, A.WIDGET_ID, W.VERSION_NUMBER, SUBSTR(A.ATTR_VALUE, 1, 60) ATTR_VALUE FROM OPB_WIDGET_ATTR A, OPB_WIDGET W, OPB_SUBJECT S, OPB_WIDGET_INST I, OPB_MAPPING M WHERE A.WIDGET_ID = W.WIDGET_ID AND W.IS_VISIBLE = 1 AND A.VERSION_NUMBER = W.VERSION_NUMBER AND A.WIDGET_TYPE IN(2, 3, 11) --Limit to Src/Tgt/Lkp Transformations AND W.WIDGET_ID = I.WIDGET_ID AND W.VERSION_NUMBER = I.VERSION_NUMBER AND I.MAPPING_ID = M.MAPPING_ID AND I.VERSION_NUMBER = M.VERSION_NUMBER AND W.SUBJECT_ID = S.SUBJ_ID AND UPPER(A.ATTR_VALUE) LIKE '%PARALLEL%' UNION SELECT S.SUBJ_NAME, W.TASK_NAME||'.'||TI.INSTANCE_NAME TASK_NAME, 'SQL Override' WIDGET_NAME, A.SESS_WIDG_INST_ID, TI.VERSION_NUMBER, SUBSTR(A.ATTR_VALUE, 1, 60) ATTR_VALUE FROM OPB_SWIDGET_ATTR A, OPB_TASK_INST TI, OPB_TASK W, OPB_SUBJECT S WHERE A.SESSION_ID = TI.TASK_ID AND A.VERSION_NUMBER = TI.VERSION_NUMBER AND TI.WORKFLOW_ID = W.TASK_ID AND TI.VERSION_NUMBER = W.VERSION_NUMBER AND W.IS_VISIBLE = 1 AND W.SUBJECT_ID = S.SUBJ_ID AND UPPER(A.ATTR_VALUE) LIKE '%PARALLEL%' ORDER BY 1, 2, 3, 4;

How to turn on Write Backward Compatible Session Log File for all session tasks in a folder
UPDATE OPB_TASK_ATTR A SET A.ATTR_VALUE=1 WHERE A.ATTR_ID=17 -- WBCSLF -- 102 Write performance data to repository -- 108 Collect performance data -- 105 Enable high precision AND EXISTS ( SELECT 0 FROM OPB_TASK T, OPB_SUBJECT S WHERE T.TASK_ID = A.TASK_ID AND T.VERSION_NUMBER = A.VERSION_NUMBER AND T.IS_VISIBLE = 1 AND T.SUBJECT_ID = S.SUBJ_ID AND S.SUBJ_NAME LIKE '%Sample%' ) -- AND A.INSTANCE_ID = 0 -- Reusable Session Only ;

What are today's long-running tasks


select -- the SRC_ROWS may look big if joiner is used

T.SUBJECT_AREA, T.INSTANCE_NAME, TRUNC(AVG(END_TIMESTART_TIME)*24, 2) RUN_HOUR, MIN(T.START_TIME) START_TIME, SUM(L.SRC_SUCCESS_ROWS) SRC_ROWS, SUM(L.TARG_SUCCESS_ROWS) TGT_ROWS from REP_TASK_INST_RUN T, OPB_SESS_TASK_LOG L where T.run_err_code=0 and (T.END_TIME-T.START_TIME)>= 1/24 and T.START_TIME >= TRUNC(SYSDATE)-2/24 and T.INSTANCE_ID = L.INSTANCE_ID GROUP BY T.SUBJECT_AREA, T.INSTANCE_NAME Order By RUN_HOUR desc;

Inside the Expression Transformation


select S.SUBJ_NAME, W.WIDGET_NAME, F.WIDGET_ID, F.FIELD_NAME, F.FIELD_ID, E.EXPR_ID, E.VERSION_NUMBER, E.EXPRESSION from OPB_WIDGET W, OPB_SUBJECT S, OPB_WIDGET_FIELD F, OPB_WIDGET_EXPR R, OPB_EXPRESSION E where W.SUBJECT_ID=S.SUBJ_ID and W.WIDGET_ID=F.WIDGET_ID and W.WIDGET_ID=R.WIDGET_ID AND F.FIELD_ID=R.OUTPUT_FIELD_ID and W.WIDGET_ID=E.WIDGET_ID AND R.EXPR_ID=E.EXPR_ID and W.VERSION_NUMBER = F.VERSION_NUMBER and F.VERSION_NUMBER = R.VERSION_NUMBER and R.VERSION_NUMBER = E.VERSION_NUMBER and W.IS_VISIBLE = 1 and w.WIDGET_NAME like 'EXP_SAMPLE%' order by S.SUBJ_ID, W.WIDGET_ID, F.FIELD_ID;

Which session populates the specific target table


select SUBJECT_AREA, SESSION_NAME,TARGET_NAME, MAX(SUCC_ROWS) AS ROWS#, TYPE_ID, COUNT(1) SAMPLE# from ( select SUBJECT_AREA, SESSION_INSTANCE_NAME SESSION_NAME, TYPE_ID, SUCCESSFUL_AFFECTED_ROWS SUCC_ROWS, TABLE_NAME TARGET_NAME from PM_REPO.REP_SESS_TBL_LOG WHERE TYPE_ID in (2) -- Target Only and END_TIME >= TRUNC(SYSDATE-40) and SUCCESSFUL_AFFECTED_ROWS > 0 and TABLE_NAME like :TGT_NAME||'%' ESCAPE '\' ) Group By SUBJECT_AREA, SESSION_NAME, TARGET_NAME, TYPE_ID Order By SUBJECT_AREA, TARGET_NAME, SESSION_NAME ;

How to avoid re-generating & re-transporting ABAP program after slightly changing the mapping
CR 29233 and 63134 have been opened to have fix this problem.
-- Find the current LAST_SAVED and UTC_LAST_SAVED select m.Mapping_ID, m.VERSION_NUMBER, m.Last_Saved, m.UTC_Last_Saved, v.User_ID, v.LAST_SAVED, v.UTC_LAST_SAVED, v.COMMENTS, p.PROGRAM_NAME,

p.INSTALL_TIME, p.VERSION_NUMBER ABAP_VERSION_NUM from opb_mapping m, OPB_VERSION_PROPS v, opb_program_info p where m.MAPPING_ID = v.OBJECT_ID and v.OBJECT_TYPE = 21 and m.SUBJECT_ID = v.SUBJECT_ID and m.VERSION_NUMBER = v.VERSION_NUMBER and m.MAPPING_ID = p.MAPPING_ID(+) and m.SUBJECT_ID = p.SUBJECT_ID(+) and m.VERSION_NUMBER = p.VERSION_NUMBER(+) and m.MAPPING_NAME = :MAP_NAME order by m.version_number;

Then modify the LAST_SAVED, UTC_LAST_SAVED in OPB_VERSION_PROPS and OPB_MAPPING first; then modify the VERSION_NUMBER in OPB_PROGRAM_INFO if necessary.
--The timsstamp below is just a sample update OPB_VERSION_PROPS v set last_saved='12/05/2008 09:10:11' , UTC_LAST_SAVED=1228363499 where v.OBJECT_ID = :MAP_ID and version_number = :VER_NUM and object_type = 21; update opb_mapping m set last_saved='12/05/2008 09:10:11', UTC_LAST_SAVED=1228363499 where MAPPING_ID = :MAP_ID and version_number = :VER_NUM; update opb_program_info set VERSION_NUMBER = :VER_NUM where mapping_id = :MAP_ID and subject_id = :SUB_ID;

Link from EXP_FROM.PORT_NAME to ???


select S.SUBJ_NAME, WF.INSTANCE_NAME ||'.'|| F.FIELD_NAME FROM_NAME, F.WIDGET_ID, F.FIELD_ORDER, F.FIELD_ID, WT.INSTANCE_NAME ||'.'|| T.FIELD_NAME TO_NAME, T.WIDGET_ID, T.FIELD_ORDER, T.FIELD_ID from OPB_WIDGET Z, OPB_WIDGET_INST WF, OPB_WIDGET_INST WT, OPB_WIDGET_FIELD F, OPB_WIDGET_FIELD T, OPB_WIDGET_DEP D, OPB_SUBJECT S where Z.SUBJECT_ID = S.SUBJ_ID and Z.IS_VISIBLE = 1 and Z.WIDGET_ID = F.WIDGET_ID and Z.WIDGET_ID = WF.WIDGET_ID and Z.RU_VERSION_NUMBER = WF.VERSION_NUMBER and WF.REF_VERSION_NUMBER = F.VERSION_NUMBER and WF.VERSION_NUMBER = D.VERSION_NUMBER and WF.MAPPING_ID = D.MAPPING_ID and WF.INSTANCE_ID = D.FROM_INSTANCE_ID and F.FIELD_ID = D.FROM_FIELD_ID and D.TO_INSTANCE_ID = WT.INSTANCE_ID and D.TO_FIELD_ID = T.FIELD_ID and D.MAPPING_ID = WT.MAPPING_ID and D.VERSION_NUMBER = WT.VERSION_NUMBER and WT.WIDGET_ID = T.WIDGET_ID and WT.REF_VERSION_NUMBER = T.VERSION_NUMBER and Z.WIDGET_NAME like 'EXP_FROM%' and F.FIELD_NAME like 'PORT_NAME%' order by F.FIELD_ID;

How the connection values is set at session level


select x.WORKFLOW_ID , t.TASK_ID, t.TASK_NAME, b.INSTANCE_ID, b.INSTANCE_NAME, b.SESS_WIDG_INST_ID, x.CONNECTION_NUM, x.CONNECTION_TYPE, x.CONNECTION_ID, x.CONNECTION_VALUE, c.OBJECT_NAME from opb_session s, opb_task t, OPB_SWIDGET_INST b, OPB_SESS_CNX_VALS x, opb_cnx c where c.OBJECT_ID(+) = x.CONNECTION_ID and s.MAPPING_ID = b.MAPPING_ID and s.SESSION_ID = b.SESSION_ID and s.SESSION_ID = t.TASK_ID and s.SESSION_ID = x.SESSION_ID and b.SESS_WIDG_INST_ID = x.SESS_WIDG_INST_ID and t.SUBJECT_ID = :SUBJ_ID and b.INSTANCE_NAME like :WIDGET_NAME -- Source/Target and t.TASK_NAME like :SESS_NAME order by t.task_name, b.SESS_WIDG_INST_ID;

Find Transformation Attribute Override at Session Level


select f.SUBJ_NAME Folder, t.task_name SESSION_NAME, i.INSTANCE_NAME, o.OBJECT_TYPE_NAME, a.* from opb_swidget_attr a, OPB_SWIDGET_INST i, OPB_WIDGET w, OPB_OBJECT_TYPE o, opb_task t, opb_subject f where a.attr_value in (:VALUE1, :VALUE2, :VALUE3) and i.SESSION_ID = a.SESSION_ID and i.SESS_WIDG_INST_ID = a.SESS_WIDG_INST_ID and i.WIDGET_ID = w.WIDGET_ID and i.WIDGET_TYPE = w.WIDGET_TYPE and i.WIDGET_TYPE = o.OBJECT_TYPE_ID and i.SESSION_ID= t.task_id and t.SUBJECT_ID= f.subj_id;

List all the Transformations in a given Mapping


Including the transformations within the mapplet
WITH M AS ( select M.SUBJECT_ID, M.MAPPING_ID from OPB_MAPPING M, OPB_SUBJECT S where S.SUBJ_ID = M.SUBJECT_ID and S.SUBJ_NAME LIKE :Folder_Name and M.MAPPING_NAME like :Mapping_Name ) select O.OBJECT_TYPE_NAME, W.INSTANCE_NAME, W.COMMENTS from OPB_WIDGET_INST W, OPB_OBJECT_TYPE O, M where O.OBJECT_TYPE_ID = W.WIDGET_TYPE and O.OBJECT_TYPE_NAME NOT IN ('Mapplet') and W.MAPPING_ID = M.MAPPING_ID union select O.OBJECT_TYPE_NAME, W.INSTANCE_NAME, W.COMMENTS from OPB_WIDGET_INST W, OPB_OBJECT_TYPE O, M where O.OBJECT_TYPE_ID = W.WIDGET_TYPE and O.OBJECT_TYPE_NAME NOT IN ('Mapplet', 'Output Transformation', 'Input Transformation') and W.MAPPING_ID in (

select X.MAPPING_ID from OPB_WIDGET_INST W, OPB_OBJECT_TYPE O, M, OPB_MAPPING X where W.MAPPING_ID = M.MAPPING_ID and O.OBJECT_TYPE_ID = W.WIDGET_TYPE and O.OBJECT_TYPE_NAME = 'Mapplet' and X.REF_WIDGET_ID = W.WIDGET_ID ) order by 1,2 ;

To Get the latest workflow run times between the time range select t1.* from REP_WFLOW_RUN t1, ( select workflow_id, max(workflow_run_id) as workflow_run_id from REP_WFLOW_RUN where workflow_name like 'wf_%' and START_TIME between to_date ('2010-09-30 12:00:00', 'YYYY-MM-DD HH24:MI:SS') and to_date ('2010-09-30 18:00:00', 'YYYY-MM-DD HH24:MI:SS') and run_status_code = 1 group by workflow_id ) t2 where t1.workflow_id=t2.workflow_id and t1.workflow_run_id=t2.workflow_run_id order by t1.START_TIME Purpose : To Find Tracing Level for Session Query : select task_name,decode (attr_value,0,'None',1,'Terse',2,'Normal',3,'Verbose Initialisation',4,'Verbose Data','') Tracing_Level from REP_SESS_CONFIG_PARM CFG,opb_task TSK WHERE CFG.SESSION_ID=TSK.TASK_ID and tsk.TASK_TYPE=68 and attr_id=204 and attr_type=6 Description : This query will give tracing information along with session names.This query is helpful in identifying the session which are having particular type of Tracing level like Verbose. Purpose : To Find name of all stored procedure being used in stored procedure transformation Query : select attr_value from OPB_WIDGET_ATTR where widget_type=6 and attr_id=1 Description : This query is helpful when you require to know name of all stored procedure being used in informatica. Purpose : To find who saved mapping last time

Query : SELECT substr(rpl.event_time,7,4) substr(rpl.event_time,6,1) substr(rpl.event_time,1,5) ' ' substr(rpl.event_time,12,11) "EventTimestamp" , usr.user_name "Username", DECODE(rpl.object_type_id,21,s21.subj_name,('('rpl.object_type_id')')) "Folder", obt.object_type_name "Type", DECODE(rpl.object_type_id,21,map.mapping_name,('('rpl.object_type_id')')) "Object" FROM opb_reposit_log rpl,opb_object_type obt, opb_subject fld,opb_mapping map,opb_users usr,opb_subject s21 WHERE obt.object_type_name = 'Mapping' AND rpl.object_type_id = obt.object_type_id AND rpl.object_id = map.mapping_id(+) AND rpl.object_id = fld.subj_id(+) AND rpl.event_uid = usr.user_id AND map.subject_id = s21.subj_id(+) ORDER BY(substr(rpl.event_time,7,4) substr(rpl.event_time,6,1) substr(rpl.event_time,1,5) ' ' substr(rpl.event_time,12,11)) DESC Description : This query is helpful when you want to know who saved the mapping last time .

Repository Query for finding the mapping name having the target file as FLAT file
select opb_subject.subj_name , opb_mapping.mapping_name from opb_widget_inst, opb_mapping, opb_targ, opb_subject where opb_widget_inst.widget_id = opb_targ.target_id and opb_widget_inst.mapping_id = opb_mapping.mapping_id and opb_subject.subj_id = opb_mapping.subject_id and opb_targ.target_name = 'YOUR_FLAT_FILE_TARGET_NAME'

Repository Query for find the list of targets


SELECT t.SUBJECT_AREA AS FOLDER_NAME, t.TARGET_NAME, t.PARENT_TARGET_DATABASE_TYPE FROM informatica.REP_ALL_TARGETS t WHERE

t.subject_area = 'ETL_MIDR_SharedObjects' AND t.target_name LIKE '%TINV_%';

You might also like