HPlogo ALLBASE/SQL Database Administration Guide: HP 3000 MPE/iX Computer Systems > Appendix G SQLGEN

GENERATE STATISTICS

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Index

Generates SQL commands necessary to UPDATE STATISTICS for one or more tables of a DBEnvironment.

Scope

SQLGEN Only

SQLGEN Syntax

>> [GENERATE] STAT[ISTICS] Schema File Name or '//' to STOP command >> SchemaFileName Owner Name >> OwnerName Do you wish to specify Table Names for each Owner (n/y)? { N O Y ES } Table Name for Owner OwnerName >> TableName

Parameters

SchemaFileName

is the name of the schema file where SQLGEN places the generated commands.

OwnerName

is the name of the owner for whom you want to UPDATE STATISTICS.

NO or YES

respond NO to select all table names for the owner; respond YES to specify certain tables for the owner.

TableName

is the name of a table for which you wish to UPDATE STATISTICS.

Example

   >> generate statistics



   ALLBASE/SQL Command Generator for Statistics



   Schema File Name or '//' to STOP command >> statpart



   Please enter Owner Names. Type @ for all, ? for a list of

   Owner Names, or RETURN to quit.



   Owner Name >> purchdb

   Do you wish to specify Table Names for each Owner (n/y)? n



   Generating UPDATE STATISTICS for PURCHDB.INVENTORY

   Generating UPDATE STATISTICS for PURCHDB.ORDERITEMS

          .                           .

          .                           .

          .                           .



   Owner Name >>   Return 



   >>


Schema File Produced

   UPDATE STATISTICS FOR TABLE PURCHDB.INVENTORY;



   UPDATE STATISTICS FOR TABLE PURCHDB.ORDERITEMS;



   UPDATE STATISTICS FOR TABLE PURCHDB.ORDERS;



   UPDATE STATISTICS FOR TABLE PURCHDB.PARTS;



   UPDATE STATISTICS FOR TABLE PURCHDB.SUPPLYPRICE;



   UPDATE STATISTICS FOR TABLE PURCHDB.VENDORS;



   COMMIT WORK;


Feedback to webmaster