extract
Creates a text file containing object definitions extracted from the database.
Authorization
To extract scheduling object, you must have display access to the objects being copied and, if you want to use the ;lock keyword, also the modify access. If you do not have the required access composer is unable to find the objects.
To extract security objects, you must have permission for the modify action on the object type file with attribute name=security.
- set the WA_EXPORT_PWD environment variable in the shell where you plan to run the command
- specify the password at the command prompt
Syntax
{create | cr | extract | ext} filename from
{[calendars | calendar | cal=[folder/]calname] |
[eventrule | erule | er=[folder/]eventrulename] |
[parms | parm | vb=[[folder/]tablename.]variablename] |
[vartable | vt=[folder/]tablename] |
[prompts | prom=[folder/]promptname] |
[resources | resource | res=[[folder/]workstationame#][folder/]resourcename] |
[runcyclegroup | rcg=[folder/]runcyclegroupname] |
[cpu={[folder/]workstationame | [folder/]workstationclassname | domainame}] |
[workstation | ws=[folder/]workstationame] |
[workstationclass | wscl=[folder/]workstationclassname] |
[domain | dom=domainame] |
[jobs | jobdefinition | jd=[[folder/]workstationame#][folder/]jobname] |
[sched | jobstream | js= [[folder/]workstationame#][folder/]jstreamname
[valid from date|valid to date |valid in date date]
[;full]] |
[users | user=[[folder/]workstationame#]username [;password]] |
[accesscontrollist | acl for securitydomainname] |
[securitydomain | sdom=securitydomainname] |
[securityrole | srol=securityrolename]}
[;lock]
Arguments
- filename
- Specifies the name of the file to contain the object definitions.
- calendars | calendar | cal
- If no argument follows, copies all calendar definitions into the file.
If argument [folder/]calname follows, copies the calname calendar into the file. Wildcard characters are permitted.
- eventrule | erule | er
- If no argument follows, copies all event rule definitions into the XML file.
If argument [folder/]eventrulename follows, copies the eventrulename event rule into the file. Wildcard characters are permitted.
- parms | parm | vb
- If no argument follows, copies all global variable definitions found in the default variable
table into the file.
If argument [folder/]tablename.variablename follows, copies the variablename variable of the specified tablename variable table into the file. If the tablename variable table is omitted, composer looks for the variable definition in the default variable table. Wildcard characters are permitted on both tablename variable table and variablename variable.
For example:
Copies all variables from all tables.create parmfile from parms=@.@
Copies all variables from the default table.create parmfile from parms=@
Copies all the variables whose name starts withcreate parmfile from parms=@.acct@
acct
from all the existing tables.Remember: Using the ;lock option on a variable locks the variable table that contains it. This implies that, while the table is locked, no other user can run any other locking commands on it or on the variables it contains. - vartable | vt
- If no argument follows, copies all variable table definitions into the file.
If argument [folder/]tablename variable table follows, copies the tablename variable table into the file. Wildcard characters are permitted.
- prompts | prom
- If no argument follows, copies all prompt definitions into the file.
If argument [folder/]promptname follows, copies the promptname prompt into the file. Wildcard characters are permitted.
- resources | resource | res
- If no argument follows, copies all resource definitions into the file.
If argument [folder/]workstationame#resourcename follows, copies the resourcename resource of the workstationame workstation in the specified folder on which the resource is defined. If workstationame is omitted, the default is the workstation on which composer is running. Wildcard characters are permitted.
- runcyclegroup | rcg
- If no argument follows, copies all run cycle group definitions into the file.
If argument [folder/]runcyclegroupname follows, copies the runcyclegroupname run cycle group into the file. Wildcard characters are permitted.
- cpu
- Copies workstations, workstation classes, or domains into the file.
- [folder/]workstation
- The name of the workstation. Wildcard characters are permitted.
- [folder/]workstationclass
- The name of the workstation class. Wildcard characters are permitted.
- domain
- The name of the domain. Wildcard characters are permitted.
- workstation | ws
- If no argument follows, copies all workstation definitions into the file.
If argument [folder/]workstationname follows, copies the workstationname workstation. Wildcard characters are permitted.
- domain | dom
- If no argument follows, copies all domain definitions into the
file.
If argument domainname follows, copies the domainname domain into the file. Wildcard characters are permitted.
- workstationclass | wscl
- If no argument follows, copies all workstation class definitions into the file.
If argument [folder/]workstationclassname follows, copies the workstationclassname workstation class. Wildcard characters are permitted.
- jobs | jobdefinition | jd
- If no argument follows, copies all job definitions into the file.
If argument workstationame#[folder/]jobname follows, copies the [folder/]jobname job, optionally defined in the folder named [folder/] of the workstationame workstation on which the job runs into the file. If folder is omitted, the default folder ("/") is used.
You can use the com.hcl.ws.showRootFolder property in the TWSConfig.properties file to manage how jobs located in the root folder are displayed. The job name can either be displayed indicating the root folder (/MYJOB1
), or without indicating it (MYJOB1
). By default, this property is set to NO which specifies to display the job without indicating the root folder. Set the property to YES to display job names preceded by root ("/") . The TWSConfig.properties file is located in the path:- On Windows operating systems
- TWA_home\usr\servers\engineServer\resources\properties
- On UNIX operating systems
- TWA_DATA_DIR/usr/servers/engineServer/resources/properties
If workstationame is omitted, the default is the workstation on which composer is running. Wildcard characters are permitted for workstationame, [folder/], and jobname.
- sched | jobstream | js
- If no argument follows, copies all job stream definitions into the file.
If argument workstationame#[folder/]jstreamname follows, copies the jstreamname job stream, optionally defined in the folder named [folder/], of the workstationame workstation on which the job stream is defined into the file. If folder is omitted, the default folder ("/") is used.
You can use the com.hcl.ws.showRootFolder property in the TWSConfig.properties file to manage how job streams located in the root folder are displayed. The job stream name can either be displayed indicating the root folder (/MYJOBSTREAM1
), or without indicating it (MYJOBSTREAM1
). By default, this property is set to NO which specifies to display the job stream name without indicating the root folder. Set the property to YES to display job stream names preceded by root ("/"). The TWSConfig.properties file is located in the path:- On Windows operating systems
- TWA_home\usr\servers\engineServer\resources\properties
- On UNIX operating systems
- TWA_DATA_DIR/usr/servers/engineServer/resources/properties
If workstationame is omitted, the default is the workstation on which composer is running. Wildcard characters are permitted for workstationame, [folder/], and jstreamname.- valid from
- date Restricts the selection to job streams that have a valid from date equal to the indicated value. The format is mm/dd/yyyy.
- valid to
- date Restricts the selection to job streams that have a valid to date equal to the indicated value. The format is mm/dd/yyyy.
- valid in
- date date The time frame during which the job stream can run. The format is mm/dd/yyyy - mm/dd/yyyy. One of the two dates can be represented by @.
- full
- Copies also all job definitions contained in the job stream.
- users | user
- If no argument follows, copies all user definitions into the file.
If argument [folder/]workstationame#username follows, copies the username user of the workstationame workstation in the specified folder on which the user is defined into the file. If workstationame is omitted, the default is the workstation on which composer is running. Wildcard characters are permitted.
If you do not add the ;password option, the password defined for the user is saved in the output file as a sequence of 10 asterisks (*) and cannot be reused.
If you do add the ;password option, the password defined for the user is encrypted and saved in the output file. It can thus be re-imported and used again.
- accesscontrollist | acl
- If no securitydomainname argument follows, copies the
access control list definitions for all the security domains into
the file.
If argument securitydomainname follows, copies the access control list definitions for the securitydomainname security domain into the file. Wildcard characters are permitted for securitydomainname .
- securitydomain | sdom
- If no securitydomainname argument follows, copies all
the security domain definitions into the file.
If argument securitydomainname follows, copies the securitydomainname security domain definition into the file. Wildcard characters are permitted for securitydomainname .
- securityrole | srol
- If no securityrolename argument follows, copies all the
security role definitions into the file.
If argument securityrolename follows, copies the securityrolename security role definition into the file. Wildcard characters are permitted for securityrolename .
- ;lock
- Specifies to keep locked the selected object.
Comments
You can use this command to create a file containing parameter definitions to be imported into the parameter database defined locally on a workstation. For more information on how to import parameter definitions locally, refer to parms.
You can invoke the command with the old name “create” or the new name “extract”. Without the lock option, database locking is not checked and all matching objects are extracted to the file. After you create a file, you can use the edit command to make changes to the file and the add or replace command to add or update the database.
You can specify with the lock option, if the objects that respond to the selected criteria, must remain locked by the user in the database. If composer, during the extraction, find some of these objects already locked by someone else, these objects are not inserted into the file and a message to stdout is presented for each locked object.
Examples
caltemp
containing
all calendars, run the following command: create caltemp from calendars=@
stemp
containing
all job streams defined on the workstation where composer runs,
run the following command: cr stemp from jobstream=@
alljobs.txt
containing all job
definitions, run the following command: extract alljobs.txt from jd=@#@
allrules.xml
containing
all event rule definitions, run the following command: ext allrules.xml from erule=@
dbmainadm.txt
with
the definition of user princeps
of workstation dbserv349
,
including the encrypted password, run:composer extract c:\dbmainadm.txt from user=dbserv349#princeps;password
The
contents of file dbmainadm.txt
will be:USERNAME princeps
PASSWORD "ENCRYPT:EIu7PP+gvS8="
END
Austin
in folder
Texas
, run the command:create ws Texas/Austin