defncopy (1) Linux Manual Page
defncopy – extract procedures and views from a Microsoft server.
Synopsis
[-v ] [-U username ] [-P password ] [-S server ] [-D database ] [-i input_file ] [-o output_file ] Bo owner.object_name [owner.object_name … ] BcDescription
is a utility program distributed with FreeTDS. It replaces a similar program of the same name distributed by Sybase. reads the text of a stored procedure or view, and writes a script suitable for recreating the procedure or view. For tables, it reads the output of sp_help and constructs a `CREATE’ TABLE statement, complete with `CREATE’ INDEX Ns , too. owner is optional if you or the database owner is the owner of the procedure/view being copied. object_name is the name of the system object you wish to extract.
Options
- -U username
- database server login name.
- -P password
- database server password.
- -S server
- database server to which to connect.
- -D database
- database to use. Optional if the procedure/view being extracted is in your default database.
- -i input_file
- a script to apply to the database. Not currently implemented.
- -o output_file
- a file to hold the script, defaults to standard output.
- -v
- Show version information and copyright notice.
Notes
is a filter; it reads from standard input, writes to standard output, and writes errors to standard error. The –i –o and –e options override these defaults. makes use of the db-lib API provided by FreeTDS. This API is of course also available to application developers.
Exit Status
exits 0 on success, and >0 if the server cannot process the query. will report any errors returned by the server, but will continue processing.
