What is the difference between Worker node, Backup node, Primary node, Secondary node, Gateway node?
July 7, 2016
What is the importance of Unix Scripting? In which scenarios do we use UNIX scripting as admin as well as developer.
July 18, 2016
Show all

PMREP Commands

To connect to the Repository:

pmrep connect -r <REPOSITORY NAME> -d <DOMAIN NAME> -n <USER> -x <PASSWORD>

 To get the list of  Workflow Objects:

pmrep listobjects -o workflow -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import.txt

 To get the list of  Source Objects:

pmrep listobjects -o Source -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import.txt

 To get the list of  Target Objects:

pmrep listobjects -o Target -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import.txt

 To get the list of  Mapplet Objects:

pmrep listobjects -o Mapplet -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import_mpplt.txt

 To get the list of  Transformation Objects:

pmrep listobjects -o Transformation -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import_mpplt.txt

 To get the list of  Worklet Objects:

pmrep listobjects -o Worklet -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > /wf_import_wrklt.txt

 To get the list of  Stored Procedures Objects:

pmrep listobjects -o transformation -t stored_procedure -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import_stproc.txt

 To get the list of Reusable Sessions:

pmrep listobjects -o session -f <FOLDER> | sed ‘1,8d;/successfully/,$d’ > wf_import_sess.txt

 To get the list of Folders:

pmrep listobjects -o folder > listfolders.txt;

 To get the list of User Connections:

pmrep listuserconnections sed ‘1,8d;/successfully/,$d’ > wf_Connecctions.txt

 To get the list of Tables by Session (Listtablesbysess):

pmrep listtablesbysess -f INFA -s <SESSION NAME> -t target

pmrep listtablesbysess -f INFA -s <SESSION NAME> -t source

 To get the list of  Dependencies:

pmrep ListObjectDependencies -n <SESSION NAME> -o session -f <FOLDER> -p both

To Export Various Objects

To export the Source object:

pmrep objectexport -n <DB.SourceName> -o Source -f <Folder Name> -m -s -b -r –u <xml file name>;

To export the Target Object:

pmrep objectexport -n <TargetName> -o Target -f <Folder Name> -m -s -b -r –u <xml file name>;

To export the Transformation Objects:

pmrep objectexport -n  <LKP Name> -o Transformation -t lookup_procedure -f <folder> -m -s -b -r -u LKP_ORDER.xml;

To export the command Task:

pmrep objectexport -n <Task Name>  -o Task -t Command -f <FOLDER>-m -s -b -r -u tsk_icr_dly_delete_persistent_files.xml;

To export the Mapplet:

pmrep objectexport -n <Mapplet name> -o Mapplet -f <Folder Name> -m -s -b -r –u <xml file name>;

To export the Mapping:

pmrep objectexport -n <Mapping name> -o Mapping -f <Folder Name> -m -s -b -r –u <xml file name>;

To export the Session:

pmrep objectexport -n <Session name> -o Session -f <Folder Name> -m -s -b -r –u <xml file name>;

To Export the Worklet:

pmrep objectexport -n <Worklet name> -o Worklet -f <Folder Name> -m -s -b -r –u <xml file name>;

To Export the Workflow:

pmrep objectexport -n <Workflow name> -o Workflow -f <Folder Name> -m -s -b -r –u <xml file name>;

 

To Find Checkouts:

To find checkout objects of all folders and all users

pmrep findcheckout -u all users > /infa/etl/output.txt;

Find checkout objects of only <XYZ> Folder

pmrep findcheckout -f XYZ -u all users > /infa/etl/output.txt;

Connections:

CreateConnection

createconnection
-s <connection_type>
-n <connection_name>
-u <user_name>
[-p <password> |
-P <password_environment_variable>]
[-c <connect string> (required for Oracle, Informix, DB2, and ODBC)]
-l <code_page>
[-r <rollback_segment> (valid for Oracle connection only)]
[-e <connection_environment_SQL>]
[-f <transaction_environment_SQL>]
[-z <packet_size> (valid for Sybase ASE and MS SQL Server connection)]
[-b <database_name> (valid for Sybase ASE, Teradata and MS SQL Server connection)]
[-v <server_name> (valid for Sybase ASE and MS SQL Server connection)]
[-d <domain name> (valid for MS SQL Server connection only)]
[-t (enable_trusted_connection, valid for MS SQL Server connection only)]
[-a <data_source_name> (valid for Teradata connection only)]
[-x (enable advanced security, lets users give Read, Write and Execute
permissions only for themselves.)]
[-k <connection_attributes> (attributes have the format
name=value;name=value; and so on)]

pmrep createconnection -s Oracle -n TEST -u xyz -p qwerty -c o20T -l US-ASCII

UpdateConnection:

Updates the user name, password, connect string, and attributes for a database connection.

updateconnection

-t <connection_subtype >

-d <connection_name>

[-u <new_user_name>]

[-p <new_password>|

P <new_password_environment_variable>]

[-c <new_connection_string>]

[-a <attribute_name> -v <new_attribute_value>]

[ -s <connection type application, relational, ftp, loader or queue > ]

[-l <code page>]

pmrep updateconnection -t <DB>  -d <Connection Name>  -u <USER>  -p <PWD> -c <Connection String>

pmrep updateconnection -t Oracle -d TEST -u def -p xyz -c orcl

 

DeleteConnection:

deleteconnection
-n <connection_name>
[-f (force delete)]
[-s <connection type application, relational, ftp, loader or queue>]

pmrep deleteconnection -n TEST -f -s Relational

To Validate the mappings:

pmrep validate -n <Mapping Name>  -o mapping -f <Folder> -s -k -m TEST

To Modify Folder Owner and Permission

pmrep modifyfolder -n <Folder> -o Admin -p 777

Execution of a Query:

pmrep executequery -q Folder_Backup -t shared -u /infa/etl/Folderquerylist.txt

To Import and object:

pmrep objectimport -i wf_check_dly.xml -c importtestctlfile.xml -l /infa/etl/temp/import.log

pmrep objectimport -i /infa01/etldata/temp/wf_check_dly.xml -c /infa/etl/temp/importctlfile.xml -l /infa/etl/temp/import.log

 

Starting a session in worklet using pmrep commands:

pmcmd starttask -sv <ServerName> -d domain_name -u Administrator -p pwd -f <FOLDER>-w wf_load_dly s_dly_credit_fact

 

Leave a Reply

Your email address will not be published. Required fields are marked *

Share
+1
Tweet
Pin
Share