Package and synonym doc update.

This commit is contained in:
Susan Douglas 2016-10-27 09:45:28 +01:00 committed by Dave Page
parent 60a0ed61b0
commit 6c45eea1a0
9 changed files with 21 additions and 31 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 92 KiB

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 34 KiB

View File

@ -1,18 +1,19 @@
.. _package:
.. _package_dialog:
******************
The Package Dialog
******************
Use the *Package* dialog to create a set of related database objects.
Use the *Package* dialog to create a (user-defined) package specification.
The *Package* dialog organizes the development of a package through the following dialog tabs: *General*, *Code*, and *Security*. The *SQL* tab displays the SQL code generated by dialog selections.
The *Package* dialog organizes the management of a package through the following dialog tabs: *General*, *Code*, and *Security*. The *SQL* tab displays the SQL code generated by dialog selections.
.. image:: images/package_general.png
Use the fields in the *General* tab to identify the package:
* Use the *Name* field to add a descriptive name for the package. The name of a new package must not match any existing package in the same schema.
* Select the schema in which the package will reside from the drop-down listbox in the *Schema* field.
* Store notes about the package in the *Comment* field.
Click the *Code* tab to continue.
@ -21,36 +22,31 @@ Click the *Code* tab to continue.
Use the fields in the *Code* tab to specify the package contents and to provide implementation details:
* Use the *Header* field to write the code that will call the database objects.
* Use the *Body* field to write the code that will implement functions, procedures, and other package contents.
* Use the *Header* field to define the public interface for the package.
* Use the *Body* field to provide the code that implements each package object.
Click the *Security* tab to continue.
.. image:: images/package_security.png
Use the fields in the *Security* tab to to assign privileges to a role. Click the *Add* icon (+) to set privileges for the package:
Use the fields in the *Security* tab to to assign EXECUTE privileges for the package to a role. Click the *Add* icon (+) to set privileges for the package:
* Select the name of the role from the drop-down listbox in the *Grantee* field.
* Click inside the *Privileges* field. Check the boxes to the left of one or more privileges to grant the selected privilege to the specified user.
* Select the name of the role from the drop-down listbox in the *Grantor* field. The default grantor is the owner of the database.
* Click inside the *Privileges* field. Check the boxes to the left of a privilege to grant the selected privilege to the specified user.
* Select the name of a role from the drop-down listbox in the *Grantor* field. The default grantor is the owner of the package.
Click the *Add* icon (+) to assign additional privileges; to discard a privilege, click the trash icon to the left of the row and confirm deletion in the *Delete Row* popup.
Click the *Add* icon (+) to assign additional privileges; to discard a privilege, click the trash icon to the left of the row, and confirm the deletion in the *Delete Row* popup.
Click the *SQL* tab to continue.
Your entries in the *Package* dialog generate a SQL command (see an example below). Use the *SQL* tab for review; revisit or switch tabs to make any changes to the SQL command.
**Example**
The following is an example of the sql command generated by user selections in the *Package* dialog:
Your entries in the *Package* dialog generate a SQL command that creates or modifies a package definition:
.. image:: images/package_sql.png
The example shown demonstrates creating a package named *registration* that includes two functions and one procedure.
The example shown demonstrates creating a package named *empinfo* that includes one function and one procedure.
* The *Info* button (i) is disabled for this dialog.
* Click the *Save* button to save work.
* Click the *Cancel* button to exit without saving work.
* Click the *Reset* button to restore configuration parameters.
* Click the *Reset* button to delete any changes to the dialog.

View File

@ -1,4 +1,4 @@
.. _synonym:
.. _synonym_dialog:
******************
The Synonym Dialog
@ -13,29 +13,23 @@ The *Synonym* dialog organizes the development of a synonym through the *General
Use the fields in the *General* tab to identify the synonym:
* Use the *Name* field to specify the alternate name for the target object. The name will be displayed in the *pgAdmin* tree control.
* Use the drop-down listbox next to *Owner* to select a role.
* Select the name of the local schema in which the synonym will reside from the drop-down listbox in the *Schema* field.
* Use the *Name* field to specify the name of synonym. The name will be displayed in the *pgAdmin* tree control.
* Select the name of the schema in which the synonym will reside from the drop-down listbox in the *Schema* field.
In the definition panel, identify the target:
* Use the drop-down listbox next to *Target Type* to select the the type of object the synonym references.
* Use the drop-down listbox next to *Target Schema* to select the name of the target schema.
* Use the drop-down listbox next to *Target Object* to select the name of the target object.
* Use the drop-down listbox next to *Target Type* to select the the type of object referenced by the synonym.
* Use the drop-down listbox next to *Target Schema* to select the name of the schema in which the object resides.
* Use the drop-down listbox next to *Target Object* to select the name of the object referenced by the synonym.
Click the *SQL* tab to continue.
Your entries in the *Synonym* dialog generate a SQL command (see an example below). Use the *SQL* tab for review; revisit the *General* tab to make any changes to the SQL command.
**Example**
The following is an example of the sql command generated by user selections in the *Synonym* dialog:
Your selections and entries in the *Synonym* dialog generate a SQL command.
.. image:: images/synonym_sql.png
The example shown demonstrates creating a synonym that replaces *calendar_styleb* with *page-per-day*.
The example creates a synonym for the *emp* table named *emp_hist*.
* The *Info* button (i) is disabled for this dialog.
* Click the *Save* button to save work.
* Click the *Cancel* button to exit without saving work.
* Click the *Reset* button to restore configuration parameters.