2. Using Ingres Commands : copyrep Command--Copy a Report to a Text File
 
Share this page                  
copyrep Command--Copy a Report to a Text File
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:
1. Copy one or more reports from a database to a text file using the copyrep command.
2. Copy the reports from the text file into a database using the sreport command.
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 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]
dbname
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.
filename
Specifies the name of a text file in which to write the report definitions.
reportname
Specifies the name of the report to be copied.
-f
Writes the reports out in the same format as the Archive operation accessed through the Reports Catalog frame of RBF. For reports created with RBF, this strips out many of the statements.
-s
Suppresses status messages.
-uusername
Specifies the effective user for the session, as described in Standard Flags and Parameters.
-Ggroupid
Specifies a group identifier, as described in Standard Flags and Parameters.
On VMS, enclose this parameter in double quotation marks (“‑Ggroupid”).