The copyrep command copies a report specification from a database to a text file. The reports must have been created by either Report-By-Forms (RBF) or Report-Writer.
Copying a report into a new database is a two-step process:
You can use the copyrep and sreport commands to copy a report from one database to another. You can use also these commands to change ownership of a report. To do this, copy out a report owned by a particular user into a text file and then copy the report back into the database under the ownership of another user.
For a complete description and examples of these commands, see the Character-based Querying and Reporting Tools User Guide. For a discussion on using the copyrep and sreport commands to change ownership of a report, see the Database Administrator Guide.
The copyrep command has the following format:
copyrep dbname |vnode::dbname[/server_class] filename reportname {reportname}
[-f] [-s] [-uusername] [-Ggroupid]
Specifies the name of the database containing the reports to be copied. Also specifies the vnode and server_class, if required, as described in Standard Flags and Parameters.
Specifies the name of a text file in which to write the report definitions.
Specifies the name of the report to be copied.
Writes the reports out in the same format as is done with the Archive operation accessed through the Reports Catalog frame of RBF. For reports created with RBF, this strips out many of the statements.
Suppresses status messages.
Specifies the effective user for the session, as described in Standard Flags and Parameters.
Specifies a group identifier, as described in Standard Flags and Parameters.
On VMS, enclose this parameter in double quotation marks ("Ggroupid").
The following example copies a report called emphours in the emp database into a text file called emphours.rw:
copyrep emp emphours emphours.rw