HP Part Number: 544530-001
Published: May 2007
Edition: HP Neoview Release 2.1
© Copyright 2007 Hewlett-Packard Development Company, L.P.
Legal Notice
Confidentialcomputersoftware.ValidlicensefromHPrequiredforpossession,useorcopying.ConsistentwithFAR12.211and12.212,Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor’s standard commercial license.
Theinformationcontainedhereinissubjecttochangewithoutnotice.TheonlywarrantiesforHPproductsandservicesaresetforthintheexpress warrantystatementsaccompanyingsuchproductsandservices. Nothinghereinshouldbeconstruedasconstitutinganadditionalwarranty. HP shall not be liable for technical or editorial errors or omissions contained herein.
Export of the information contained in this publication may require authorization from the U.S. Department of Commerce.
Microsoft, Windows, and Windows NT are U.S. registered trademarks of Microsoft Corporation.
Intel, Pentium, and Celeron are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States and other countries.
Java is a U.S. trademark of Sun Microsystems, Inc.
Motif, OSF/1, UNIX, X/Open, and the "X" device are registered trademarks, and IT DialTone and The Open Group are trademarks of The Open Group in the U.S. and other countries.
OpenSoftwareFoundation,OSF,theOSFlogo,OSF/1,OSF/Motif,andMotifaretrademarksoftheOpenSoftwareFoundation,Inc. OSFMAKES NOWARRANTYOFANYKINDWITHREGARDTOTHEOSFMATERIALPROVIDEDHEREIN,INCLUDING,BUTNOTLIMITEDTO,THE IMPLIEDWARRANTIESOFMERCHANTABILITYANDFITNESSFORAPARTICULARPURPOSE.OSFshallnotbeliableforerrorscontained herein or for incidental consequential damages in connection with the furnishing, performance, or use of this material.
© 1990, 1991, 1992, 1993 Open Software Foundation, Inc. The OSF documentation and the OSF software to which it relates are derived in part from materials supplied by the following:© 1987, 1988, 1989 Carnegie-Mellon University. © 1989, 1990, 1991 Digital Equipment Corporation. © 1985, 1988, 1989, 1990 Encore Computer Corporation. © 1988 Free Software Foundation, Inc. © 1987, 1988, 1989, 1990, 1991 Hewlett-Packard Company. © 1985, 1987, 1988, 1989, 1990, 1991, 1992 International Business Machines Corporation. © 1988, 1989 Massachusetts Institute of Technology. © 1988, 1989, 1990 Mentat Inc. © 1988 Microsoft Corporation. © 1987, 1988, 1989, 1990, 1991, 1992 SecureWare, Inc. © 1990, 1991 SiemensNixdorfInformationssystemeAG.©1986,1989,1996,1997SunMicrosystems,Inc.©1989,1990,1991TransarcCorporation.OSFsoftware anddocumentationarebasedinpartontheFourthBerkeleySoftwareDistributionunderlicensefromTheRegentsoftheUniversityofCalifornia. OSFacknowledgesthefollowingindividualsandinstitutionsfortheirroleinitsdevelopment:KennethC.R.C.Arnold,GregoryS.Couch,Conrad C. Huang, Ed James, Symmetric Computer Systems, Robert Elz. © 1980, 1981, 1982, 1983, 1985, 1986, 1987, 1988, 1989 Regents of the University of California.
Table of Contents |
|
About This Document....................................................................................................... |
15 |
Intended Audience................................................................................................................................ |
15 |
New and Changed Information in This Edition................................................................................... |
15 |
Document Organization....................................................................................................................... |
15 |
Notation Conventions........................................................................................................................... |
16 |
General Syntax Notation................................................................................................................. |
16 |
Related Documentation........................................................................................................................ |
17 |
Neoview Customer Library............................................................................................................. |
18 |
Neoview Support Library................................................................................................................ |
18 |
Publishing History................................................................................................................................ |
19 |
HP Encourages Your Comments.......................................................................................................... |
19 |
1 Introduction to Neoview Script................................................................................... |
21 |
2 Installing Neoview Script............................................................................................. |
23 |
Preinstallation Procedures.................................................................................................................... |
23 |
Installing and Verifying the Java Runtime Environment (JRE)...................................................... |
23 |
Installing a Supported Java Version........................................................................................... |
23 |
Verifying the Java Version.......................................................................................................... |
24 |
Setting the PATH to a Supported Java Version on Windows.................................................... |
24 |
Setting the PATH to a Supported Java Version on Linux or UNIX............................................ |
26 |
Installing and Verifying the Neoview JDBC Type 4 Driver............................................................ |
26 |
Installing the JDBC Driver......................................................................................................... |
26 |
Verifying the JDBC Driver.......................................................................................................... |
26 |
Installing Perl or Python.................................................................................................................. |
27 |
Installation Procedures......................................................................................................................... |
27 |
Downloading the Installer............................................................................................................... |
27 |
Verifying the Version of the Installer File........................................................................................ |
28 |
Running the Installer....................................................................................................................... |
28 |
Installer Wizard Steps................................................................................................................ |
28 |
Launching the Installer Wizard............................................................................................ |
28 |
Using the Installer Wizard.................................................................................................... |
29 |
Command-Line Installation Steps.............................................................................................. |
33 |
Postinstallation Procedures................................................................................................................... |
34 |
Verifying the Installed Software Files.............................................................................................. |
34 |
Verifying the Installed Version of Neoview Script.......................................................................... |
35 |
Setting the Look and Feel of the Neoview Script Interface............................................................. |
35 |
Supported Look-and-Feel Types................................................................................................ |
36 |
Setting the Look and Feel at a Command-Line Prompt............................................................ |
37 |
Setting the Look and Feel in the System Properties on Windows............................................. |
37 |
Setting the Look and Feel in the User Profile on Linux or UNIX.............................................. |
39 |
Testing the Launch of Neoview Script............................................................................................ |
39 |
3 Launching the Neoview Script Interface.................................................................... |
41 |
Launching the Neoview Script Interface on Windows......................................................................... |
41 |
Creating a Shortcut to hpnvs.cmd................................................................................................... |
41 |
Launching the Neoview Script Interface on Linux or UNIX................................................................ |
44 |
Setting the PATH of hpnvs.sh.......................................................................................................... |
44 |
Table of Contents |
3 |
Presetting the Optional Launch Parameters.................................................................................... |
45 |
Logging In to the Database Platform.................................................................................................... |
45 |
Default Login................................................................................................................................... |
45 |
Login Parameters............................................................................................................................. |
46 |
Using Optional Launch Parameters................................................................................................ |
46 |
Logging In When Launching Neoview Script........................................................................... |
47 |
Running a Command When Launching Neoview Script.......................................................... |
47 |
Example of Running an SQL Statement With -q or -sql....................................................... |
48 |
Example of Running a Neoview Script Interface Command With -q or -sql....................... |
48 |
Running a Script File When Launching Neoview Script........................................................... |
48 |
Example of a Script File........................................................................................................ |
49 |
Example of Running a Script File With -s or -script............................................................. |
49 |
Launching Neoview Script Without Connecting to the Database............................................. |
49 |
Example of Launching Neoview Script File With -noconnect.............................................. |
50 |
Exiting the Neoview Script Interface.................................................................................................... |
50 |
4 Running Commands Interactively in the Neoview Script Interface......................... |
51 |
Neoview Script Interface...................................................................................................................... |
51 |
Product Banner................................................................................................................................ |
51 |
Interface Prompts............................................................................................................................ |
51 |
Breaking the Command Line........................................................................................................... |
51 |
Case Sensitivity................................................................................................................................ |
52 |
Using Neoview Script Interface Commands........................................................................................ |
52 |
Showing the Session Attributes....................................................................................................... |
52 |
Setting and Showing the Idle Timeout Value for the Session......................................................... |
53 |
Customizing the Standard Prompt.................................................................................................. |
53 |
SET PROMPT Command........................................................................................................... |
53 |
SET TIME Command................................................................................................................. |
53 |
Setting and Showing the SQL Terminator....................................................................................... |
54 |
Displaying the Elapsed Time........................................................................................................... |
54 |
Setting and Showing the Current Schema....................................................................................... |
55 |
Limiting the Result Set of a Query.................................................................................................. |
55 |
Showing Information About SQL Database Objects....................................................................... |
55 |
Showing the Schemas................................................................................................................. |
56 |
Showing the Tables in a Schema................................................................................................ |
56 |
Showing the Dependent Objects of a Table................................................................................ |
56 |
Showing the Views in a Schema................................................................................................. |
57 |
Showing the Synonyms in a Schema......................................................................................... |
57 |
Displaying Executed Commands.................................................................................................... |
58 |
Editing and Reexecuting a Command............................................................................................. |
58 |
Clearing the Interface Window....................................................................................................... |
58 |
Obtaining Help................................................................................................................................ |
58 |
Running SQL Statements...................................................................................................................... |
59 |
Executing an SQL Statement........................................................................................................... |
59 |
Repeating an SQL Statement........................................................................................................... |
59 |
Preparing and Executing SQL Statements...................................................................................... |
60 |
Preparing an SQL Statement...................................................................................................... |
60 |
Setting Parameters...................................................................................................................... |
61 |
Displaying the Parameters of the Session.................................................................................. |
61 |
Resetting the Parameters............................................................................................................ |
61 |
Executing a Prepared SQL Statement........................................................................................ |
62 |
Logging Output.................................................................................................................................... |
63 |
Starting the Logging Process........................................................................................................... |
63 |
SPOOL ON or LOG ON Command........................................................................................... |
63 |
4Table of Contents
SPOOL log-file or LOG log-file Command................................................................................ |
64 |
Using the CLEAR Option........................................................................................................... |
64 |
Logging Concurrent Neoview Script Sessions........................................................................... |
64 |
Stopping the Logging Process......................................................................................................... |
64 |
Viewing the Contents of a Log File................................................................................................. |
64 |
5 Running Scripts in the Neoview Script Interface....................................................... |
67 |
Creating a Script File............................................................................................................................. |
67 |
Supported SQL Statements in Script Files....................................................................................... |
67 |
Permitted Neoview Script Interface Commands in Script Files...................................................... |
67 |
Disallowed Interface Commands in Script Files........................................................................ |
67 |
Comments........................................................................................................................................ |
67 |
Section Headers............................................................................................................................... |
67 |
Example of a Script File................................................................................................................... |
68 |
Running a Script File............................................................................................................................. |
68 |
Logging Output.................................................................................................................................... |
69 |
Running Scripts in Parallel................................................................................................................... |
69 |
6 Running Neoview Script From Perl or Python............................................................ |
71 |
Setting the Login Environment Variables............................................................................................. |
71 |
Setting the Login Environment Variables on Windows.................................................................. |
71 |
Setting Login Environment Variables on the Command Line................................................... |
71 |
Setting Login Environment Variables in the System Properties................................................ |
72 |
Setting the Login Environment Variables on Linux or UNIX......................................................... |
73 |
Setting Login Environment Variables on the Command Line................................................... |
73 |
Setting Login Environment Variables in the User Profile.......................................................... |
74 |
Perl and Python Wrapper Scripts......................................................................................................... |
74 |
Launching Neoview Script From the Perl or Python Command Line................................................. |
74 |
Perl and Python Commands on Windows...................................................................................... |
75 |
Perl and Python Commands on Linux or UNIX............................................................................. |
75 |
Launching Neoview Script From a Perl or Python Program............................................................... |
76 |
Setting the Login Environment Variables........................................................................................ |
76 |
Using SQL Statements in a Perl or Python Program....................................................................... |
76 |
Example of a Perl Program (example.pl)................................................................................... |
76 |
Example of a Python Program (example.py)............................................................................. |
77 |
Running the Perl or Python Program.............................................................................................. |
77 |
A Neoview Script Interface Commands........................................................................ |
79 |
@ Command.......................................................................................................................................... |
81 |
Syntax.............................................................................................................................................. |
81 |
Considerations................................................................................................................................. |
82 |
Examples.......................................................................................................................................... |
82 |
/ Command........................................................................................................................................... |
82 |
Syntax.............................................................................................................................................. |
82 |
Considerations................................................................................................................................. |
82 |
Example........................................................................................................................................... |
82 |
CLEAR Command................................................................................................................................ |
83 |
Syntax.............................................................................................................................................. |
83 |
Considerations................................................................................................................................. |
83 |
Example........................................................................................................................................... |
83 |
CONNECT Command.......................................................................................................................... |
83 |
Syntax.............................................................................................................................................. |
83 |
Considerations................................................................................................................................. |
83 |
Table of Contents |
5 |
Examples.......................................................................................................................................... |
84 |
DISCONNECT Command.................................................................................................................... |
84 |
Syntax.............................................................................................................................................. |
84 |
Considerations................................................................................................................................. |
84 |
Examples.......................................................................................................................................... |
84 |
ENV Command..................................................................................................................................... |
85 |
Syntax.............................................................................................................................................. |
85 |
Considerations................................................................................................................................. |
85 |
Examples.......................................................................................................................................... |
86 |
EXIT Command.................................................................................................................................... |
86 |
Syntax.............................................................................................................................................. |
86 |
Considerations................................................................................................................................. |
87 |
Examples.......................................................................................................................................... |
87 |
FC Command........................................................................................................................................ |
87 |
Syntax.............................................................................................................................................. |
87 |
Considerations................................................................................................................................. |
88 |
Examples.......................................................................................................................................... |
88 |
HELP Command................................................................................................................................... |
90 |
Syntax.............................................................................................................................................. |
90 |
Considerations................................................................................................................................. |
90 |
Examples.......................................................................................................................................... |
90 |
HISTORY Command............................................................................................................................ |
90 |
Syntax.............................................................................................................................................. |
91 |
Considerations................................................................................................................................. |
91 |
Example........................................................................................................................................... |
91 |
LOG Command..................................................................................................................................... |
91 |
Syntax.............................................................................................................................................. |
91 |
Considerations................................................................................................................................. |
92 |
Examples.......................................................................................................................................... |
92 |
MODE Command................................................................................................................................. |
92 |
Syntax.............................................................................................................................................. |
92 |
Considerations................................................................................................................................. |
93 |
Examples.......................................................................................................................................... |
93 |
OBEY Command................................................................................................................................... |
93 |
Syntax.............................................................................................................................................. |
93 |
Considerations................................................................................................................................. |
94 |
Examples.......................................................................................................................................... |
94 |
PRUN Command.................................................................................................................................. |
95 |
Syntax.............................................................................................................................................. |
95 |
Considerations................................................................................................................................. |
96 |
Example........................................................................................................................................... |
96 |
QUIT Command................................................................................................................................... |
97 |
Syntax.............................................................................................................................................. |
97 |
Considerations................................................................................................................................. |
97 |
Examples.......................................................................................................................................... |
97 |
RECONNECT Command..................................................................................................................... |
98 |
Syntax.............................................................................................................................................. |
98 |
Considerations................................................................................................................................. |
98 |
Examples.......................................................................................................................................... |
98 |
REPEAT Command............................................................................................................................... |
98 |
Syntax.............................................................................................................................................. |
98 |
Considerations................................................................................................................................. |
99 |
Examples.......................................................................................................................................... |
99 |
RESET PARAM Command................................................................................................................... |
99 |
Syntax............................................................................................................................................. |
100 |
6Table of Contents
Considerations............................................................................................................................... |
100 |
Example......................................................................................................................................... |
100 |
RUN Command.................................................................................................................................. |
100 |
Syntax............................................................................................................................................. |
100 |
Considerations............................................................................................................................... |
100 |
Example......................................................................................................................................... |
100 |
SAVEHIST Command......................................................................................................................... |
101 |
Syntax............................................................................................................................................. |
101 |
Considerations............................................................................................................................... |
101 |
Examples........................................................................................................................................ |
101 |
SET COLSEP Command..................................................................................................................... |
101 |
Syntax............................................................................................................................................. |
102 |
Considerations............................................................................................................................... |
102 |
Examples........................................................................................................................................ |
102 |
SET HISTOPT Command.................................................................................................................... |
102 |
Syntax............................................................................................................................................. |
102 |
Considerations............................................................................................................................... |
102 |
Examples........................................................................................................................................ |
102 |
SET IDLETIMEOUT Command.......................................................................................................... |
103 |
Syntax............................................................................................................................................. |
103 |
Considerations............................................................................................................................... |
104 |
Examples........................................................................................................................................ |
104 |
SET MARKUP Command................................................................................................................... |
104 |
Syntax............................................................................................................................................. |
104 |
Considerations............................................................................................................................... |
104 |
Examples........................................................................................................................................ |
104 |
SET LIST_COUNT Command............................................................................................................ |
106 |
Syntax............................................................................................................................................. |
106 |
Considerations............................................................................................................................... |
106 |
Examples........................................................................................................................................ |
107 |
SET PARAM Command...................................................................................................................... |
107 |
Syntax............................................................................................................................................. |
108 |
Considerations............................................................................................................................... |
108 |
Examples........................................................................................................................................ |
108 |
SET PROMPT Command.................................................................................................................... |
109 |
Syntax............................................................................................................................................. |
109 |
Considerations............................................................................................................................... |
109 |
Examples........................................................................................................................................ |
109 |
SET SQLPROMPT Command............................................................................................................. |
110 |
Syntax............................................................................................................................................. |
110 |
Considerations............................................................................................................................... |
111 |
Examples........................................................................................................................................ |
111 |
SET SQLTERMINATOR Command.................................................................................................... |
112 |
Syntax............................................................................................................................................. |
112 |
Considerations............................................................................................................................... |
112 |
Examples........................................................................................................................................ |
112 |
SET TIME Command.......................................................................................................................... |
112 |
Syntax............................................................................................................................................. |
112 |
Considerations............................................................................................................................... |
112 |
Examples........................................................................................................................................ |
113 |
SET TIMING Command..................................................................................................................... |
113 |
Syntax............................................................................................................................................. |
113 |
Considerations............................................................................................................................... |
113 |
Examples........................................................................................................................................ |
113 |
SHOW COLSEP Command................................................................................................................ |
113 |
Table of Contents |
7 |
Syntax............................................................................................................................................. |
114 |
Considerations............................................................................................................................... |
114 |
Examples........................................................................................................................................ |
114 |
SHOW HISTOPT Command.............................................................................................................. |
114 |
Syntax............................................................................................................................................. |
114 |
Considerations............................................................................................................................... |
114 |
Examples........................................................................................................................................ |
114 |
SHOW IDLETIMEOUT Command..................................................................................................... |
114 |
Syntax............................................................................................................................................. |
114 |
Considerations............................................................................................................................... |
114 |
Examples........................................................................................................................................ |
115 |
SHOW LIST_COUNT Command....................................................................................................... |
115 |
Syntax............................................................................................................................................. |
115 |
Considerations............................................................................................................................... |
115 |
Examples........................................................................................................................................ |
115 |
SHOW MARKUP Command.............................................................................................................. |
115 |
Syntax............................................................................................................................................. |
115 |
Considerations............................................................................................................................... |
115 |
Examples........................................................................................................................................ |
116 |
SHOW MODE Command................................................................................................................... |
116 |
Syntax............................................................................................................................................. |
116 |
Considerations............................................................................................................................... |
116 |
Example......................................................................................................................................... |
116 |
SHOW MVGROUPS Command......................................................................................................... |
116 |
Syntax............................................................................................................................................. |
116 |
Considerations............................................................................................................................... |
117 |
Examples........................................................................................................................................ |
117 |
SHOW MVS Command...................................................................................................................... |
117 |
Syntax............................................................................................................................................. |
117 |
Considerations............................................................................................................................... |
118 |
Examples........................................................................................................................................ |
118 |
SHOW PARAM Command................................................................................................................. |
118 |
Syntax............................................................................................................................................. |
119 |
Considerations............................................................................................................................... |
119 |
Example......................................................................................................................................... |
119 |
SHOW PREPARED Command........................................................................................................... |
119 |
Syntax............................................................................................................................................. |
119 |
Considerations............................................................................................................................... |
119 |
Examples........................................................................................................................................ |
120 |
SHOW SCHEMA Command.............................................................................................................. |
120 |
Syntax............................................................................................................................................. |
120 |
Considerations............................................................................................................................... |
120 |
Example......................................................................................................................................... |
120 |
SHOW SCHEMAS Command............................................................................................................ |
120 |
Syntax............................................................................................................................................. |
120 |
Considerations............................................................................................................................... |
121 |
Examples........................................................................................................................................ |
121 |
SHOW SESSION Command............................................................................................................... |
122 |
Syntax............................................................................................................................................. |
122 |
Considerations............................................................................................................................... |
122 |
Examples........................................................................................................................................ |
123 |
SHOW SQLPROMPT Command........................................................................................................ |
123 |
Syntax............................................................................................................................................. |
123 |
Considerations............................................................................................................................... |
124 |
Example......................................................................................................................................... |
124 |
8Table of Contents
SHOW SQLTERMINATOR Command............................................................................................... |
124 |
Syntax............................................................................................................................................. |
124 |
Considerations............................................................................................................................... |
124 |
Example......................................................................................................................................... |
124 |
SHOW SYNONYMS Command......................................................................................................... |
124 |
Syntax............................................................................................................................................. |
124 |
Considerations............................................................................................................................... |
125 |
Examples........................................................................................................................................ |
125 |
SHOW TABLE Command................................................................................................................... |
125 |
Syntax............................................................................................................................................. |
126 |
Considerations............................................................................................................................... |
126 |
Examples........................................................................................................................................ |
126 |
SHOW TABLES Command................................................................................................................. |
127 |
Syntax............................................................................................................................................. |
127 |
Considerations............................................................................................................................... |
128 |
Examples........................................................................................................................................ |
128 |
SHOW TIME Command..................................................................................................................... |
128 |
Syntax............................................................................................................................................. |
129 |
Considerations............................................................................................................................... |
129 |
Example......................................................................................................................................... |
129 |
SHOW TIMING Command................................................................................................................ |
129 |
Syntax............................................................................................................................................. |
129 |
Considerations............................................................................................................................... |
129 |
Example......................................................................................................................................... |
129 |
SHOW VIEWS Command................................................................................................................... |
129 |
Syntax............................................................................................................................................. |
129 |
Considerations............................................................................................................................... |
130 |
Examples........................................................................................................................................ |
130 |
SPOOL Command............................................................................................................................... |
130 |
Syntax............................................................................................................................................. |
130 |
Considerations............................................................................................................................... |
131 |
Examples........................................................................................................................................ |
131 |
VERSION Command.......................................................................................................................... |
131 |
Syntax............................................................................................................................................. |
131 |
Considerations............................................................................................................................... |
132 |
Example......................................................................................................................................... |
132 |
B Supported SQL Statements....................................................................................... |
133 |
C Connectivity Service Commands............................................................................. |
135 |
INFO DS Command............................................................................................................................ |
135 |
Syntax............................................................................................................................................. |
135 |
Considerations............................................................................................................................... |
135 |
Example......................................................................................................................................... |
135 |
Index............................................................................................................................... |
137 |
Table of Contents |
9 |
10
List of Figures
1-1 |
Neoview Script Within a Neoview Platform Network................................................................. |
21 |
11
12
List of Tables
2-1 |
Locations of Neoview Script Software Files.................................................................................. |
34 |
13
14
This manual describes how to use the Neoview Script command-line interface on a client workstation to manage a database on a Neoview data warehousing platform. Neoview Script enables you to perform daily administrative tasks by running SQL statements interactively or from script files.
Thismanualisintendedfordatabaseadministratorsandsupportpersonnelwhoaremaintaining and monitoring a Neoview database.
Chapter or Appendix |
New or Changed Information |
“Setting the Look and Feel of the |
There is a new look and feel property value, BTEQ (to support Teradata). This |
NeoviewScriptInterface”(page35) |
property affects the formatting of status messages. The look and feel property |
|
valueOracle isnolongeravailable,butissupportedforbackwardcompatibility. |
|
For more information, see “Setting the Look and Feel of the Neoview Script |
|
Interface” (page 35). |
“Launching the Neoview Script
Interface” (page 41)
Appendix A: Neoview Script
Interface Commands
There is a new optional launch parameter -noconnect. For more information, see“LaunchingNeoviewScriptWithoutConnectingtotheDatabase”(page49).
This appendix describes these new interface commands:
•CONNECT
•RECONNECT
•SET MARKUP
•SET COLSEP
•SET HISTOPT
•SHOW COLSEP
•SHOW HISTOPT
•SHOW MARKUP
•SHOW PREPARED
This appendix also includes changes these existing interface commands:
•DISCONNECT
•ENV
•PRUN
•SESSION
•SET TIME
•SHOW TABLE
•SHOW SESSION
Chapter 1: Introduction to |
Introduces Neoview Script and describes its capabilities. |
Neoview Script |
|
Chapter 2: Installing Neoview |
Describes how to install Neoview Script on the client workstation. |
Script |
|
Chapter3:LaunchingtheNeoview |
Describes how to launch, log in to, and exit the Neoview Script interface on a |
Script Interface |
client workstation. |
Chapter 4: Running Commands |
Describes how to run commands interactively in the Neoview Script interface. |
InteractivelyintheNeoviewScript |
|
Interface |
|
Chapter 5: Running Scripts in the |
Describes how to run script files in the Neoview Script interface. |
Neoview Script Interface |
|
Intended Audience |
15 |
Chapter 6: Running Neoview |
Describes how to run Neoview Script from Perl or Python. |
Script From Perl or Python |
|
Appendix A: Neoview Script |
Provides syntax, considerations, and examples for Neoview Script interface |
Interface Commands |
commands. |
Appendix B: Supported SQL |
Lists the SQL statements that Neoview Script supports. |
Statements |
|
AppendixC:ConnectivityService Providessyntax,considerations,andexamplesforconnectivityservicecommands.
Commands
This list summarizes the notation conventions for syntax presentation in this manual.
UPPERCASE LETTERS |
Uppercaselettersindicatekeywordsandreservedwords.Typethese |
|
items exactly as shown. Items not enclosed in brackets are required. |
|
For example: |
|
SELECT |
Italic Letters |
Italic letters, regardless of font, indicate variable items that you |
|
supply. Items not enclosed in brackets are required. For example: |
|
file-name |
Computer Type |
Computer type letters within text indicate case-sensitive keywords |
|
and reserved words. Type these items exactly as shown. Items not |
|
enclosed in brackets are required. For example: |
|
myfile.sh |
[ ] Brackets |
Brackets enclose optional syntax items. For example: |
|
DATETIME [start-field TO] end-field |
|
A group of items enclosed in brackets is a list from which you can |
|
choose one item or none. The items in the list can be arranged either |
|
vertically, with aligned brackets on each side of the list, or |
|
horizontally, enclosed in a pair of brackets and separated by vertical |
|
lines. For example: |
|
DROP SCHEMA schema [CASCADE] |
|
[RESTRICT] |
|
DROP SCHEMA schema [ CASCADE | RESTRICT ] |
{ } Braces |
Braces enclose required syntax items. For example: |
|
FROM { grantee[, grantee]...} |
|
A group of items enclosed in braces is a list from which you are |
|
required to choose one item. The items in the list can be arranged |
|
either vertically, with aligned braces on each side of the list, or |
|
horizontally, enclosed in a pair of braces and separated by vertical |
|
lines. For example: |
|
INTERVAL { start-field TO end-field } |
|
{ single-field } |
|
INTERVAL { start-field TO end-field | single-field } |
16 About This Document
| Vertical Line |
Averticallineseparatesalternativesinahorizontallistthatisenclosed |
|
in brackets or braces. For example: |
|
{expression | NULL} |
… Ellipsis |
Anellipsisimmediatelyfollowingapairofbracketsorbracesindicates |
|
thatyoucanrepeattheenclosedsequenceofsyntaxitemsanynumber |
|
of times. For example: |
|
ATTRIBUTE[S] attribute [, attribute]... |
|
{, sql-expression}... |
|
Anellipsisimmediatelyfollowingasinglesyntaxitemindicatesthat |
|
you can repeat that syntax item any number of times. For example: |
|
expression-n… |
Punctuation |
Parentheses,commas,semicolons,andothersymbolsnotpreviously |
|
described must be typed as shown. For example: |
|
DAY (datetime-expression) |
|
@script-file |
|
Quotationmarksaroundasymbolsuchasabracketorbraceindicate |
|
the symbol is a required character that you must type as shown. For |
|
example: |
|
"{" module-name [, module-name]... "}" |
Item Spacing |
Spaces shown between items are required unless one of the items is |
|
apunctuationsymbolsuchasaparenthesisoracomma.Forexample: |
|
DAY (datetime-expression) |
|
DAY(datetime-expression) |
|
If there is no space between two items, spaces are not permitted. In |
|
this example, no spaces are permitted between the period and any |
|
other items: |
|
myfile.sh |
Line Spacing |
If the syntax of a command is too long to fit on a single line, each |
|
continuation line is indented three spaces and is separated from the |
|
preceding line by a blank line. This spacing distinguishes items in a |
|
continuation line from items in a vertical list of selections. For |
|
example: |
|
match-value [NOT] LIKE pattern |
|
[ESCAPE esc-char-expression] |
The HP Neoview Library consists of:
•“Neoview Customer Library”
•“Neoview Support Library” (page 18)
Related Documentation |
17 |
This manual is part of the Neoview customer library:
•Administration
Neoview Database Administrator’s Guide Information about how to load and manage the Neoview database
|
|
by using the Neoview DB Admin and other tools. |
|
Neoview DB Admin Online Help |
Context-sensitive help topics that describe how to use the HP |
|
|
Neoview DB Admin management interface. |
|
Neoview Management Dashboard Client |
InformationonusingtheDashboardClient,includinghowtoinstall |
|
Guide for Database Administrators |
theClient,startandconfiguretheClientServerGateway(CSG),use |
|
|
the Client windows and property sheets, interpret entity screen |
|
|
information,anduseCommandandControltomanagequeriesfrom |
|
|
the Client. |
|
Neoview Owner’s Manual |
Site-planning information and basic hardware information. |
|
Neoview Script Guide |
Information about using the HP Neoview Script command-line |
|
|
interface to run SQL statements interactively or from script files. |
|
Neoview Script Online Help |
Command-linehelpthatdescribestheinterfacecommandssupported |
|
|
in the current operating mode of Neoview Script. |
• |
Reference |
|
|
Neoview SQL Reference Manual |
Reference information about the syntax of SQL statements, |
|
|
functions, and other SQL language elements supported by the |
|
|
Neoview database software. |
|
Neoview Messages Manual |
Cause, effect, and recovery information for error messages. |
|
README for Neoview Platform for |
Information about known problems that are visible to customers. |
|
Release 2.1 |
|
• |
Connectivity |
|
|
Neoview JDBC Type 4 Driver API Reference |
ReferenceinformationabouttheHPNeoviewJDBCType4Driver |
|
|
API. |
|
Neoview JDBC Type 4 Driver Programmer’s |
Information about using the HP Neoview JDBC Type 4 driver, |
|
Reference |
which provides Java applications on client workstations access a |
|
|
Neoview database. |
|
Neoview ODBC Drivers Manual |
Information about using HP Neoview ODBC drivers on a client |
|
|
workstation to access a Neoview database. |
|
ODBC Client Administrator Online Help |
Context-sensitive help topics that describe how to use the ODBC |
|
|
client interface. |
|
README files |
— README for HP JDBC Type 4 Driver |
|
|
— README for HP ODBC Driver for Windows |
|
|
— README for HP ODBC Driver for Linux and HP-UX |
|
|
— README for HP Neoview Script |
Boot Application Online Help |
Reference information for using the boot software. |
Neoview Database Support Guide |
ProceduresandreferenceinformationthatareuniquetotheNeoview |
|
database software or not documented in other HP manuals. |
18 About This Document
Neoview Hardware Installation and Support |
Installation and replacement procedures. |
Guide |
|
NeoviewManagementDashboardSupportGuide Information on managing and configuring Dashboard from the Dashboard Server and Client, including starting and running Dashboard,usingDiscreteObjectThresholds(DOTs),usingDashboard CommandInterpretercommands,usingtheEntityDefinitionLanguage (EDL),andusingDashboarddatadefinitionsandrecorddeclarations.
Neoview Migration and Upgrade Guide |
Proceduresforaddinghardware,installingRVUsandupdatingother |
|
software and firmware. |
Neoview ODBC and JDBC Troubleshooting |
Guidelines for troubleshooting ODBC and JDBC connectivity to an |
Guide |
HP Neoview data warehousing platform. |
Neoview SQL Metadata Quick Reference |
Quick guide to schemas, tables, columns, and data types for Version |
|
2000 Neoview SQL metadata. |
Neoview System Console Installer Guide |
Information about installing and configuring applications on the |
|
Neoview system console |
Neoview Query Support Guide |
Information related to query execution plans and how to affect the |
|
query performance of Neoview databases |
Neoview Virtual TapeServer Installation and |
Information about installing and maintaining the Neoview Virtual |
Support Guide |
TapeServer (VTS). |
NeoviewWorkloadManagementServicesGuide Information about using Neoview Workload Management Services (NWMS) to manage workload and resources on a Neoview data warehousing platform.
Part Number |
Product Version |
Publication Date |
542714-003 |
HP Neoview Release 1.0 |
August 2006 |
543708-001 |
HP Neoview Release 1.1 |
October 2006 |
543707-001 |
HP Neoview Release 1.2 |
November 2006 |
544356-001 |
HP Neoview Release 2.0 |
March 2007 |
544530-001 |
HP Neoview Release 2.1 |
May 2007 |
HP encourages your comments concerning this document. We are committed to providing documentation that meets your needs. Send any errors found, suggestions for improvement, or compliments to:
pubs.comments@hp.com
Include the document title, part number, and any comment, error found, or suggestion for improvement you have concerning this document.
Publishing History |
19 |
20
NeoviewScriptisacommand-lineinterfacethatyoudownloadandinstallonaclientworkstation that has the Neoview JDBC Type 4 Driver installed. Operating systems that support the JDBC driverincludeWindows,Linux,andUNIX.TheJDBCdriverconnectsNeoviewScriptonaclient workstation to a Neoview database on a Neoview data warehousing platform.
Figure 1-1 Neoview Script Within a Neoview Platform Network
Neoview Script enables you to perform daily administrative and database management tasks by running SQL statements interactively or from script files. You can also run Neoview Script fromaPerlorPythoncommandlineorfromPerlorPythonprograms. NeoviewScriptsupports many SQL statements. For a list of these statements, see Appendix B (page 133).
Neoview Script does not support:
•Adding, modifying, and deleting users
•Changing user passwords
•Job scheduling
21
22
NOTE: IfyouaremanuallyinstallingNeoviewScriptonaLinuxplatformthathastheNeoview data loader installed, use the services or sysadmin ID instead of root, which has been frozen for theloader.ThebestwaytoinstallNeoviewScriptontheloaderplatformisbyusingtheNeoview LoaderSupplementalexecutive(Installsuppkt).Formoreinformation,seetheNeoviewMigration and Upgrade Guide.
To install Neoview Script, follow these procedures:
1.Preinstallation procedures:
•“Installing and Verifying the Java Runtime Environment (JRE)” (page 23)
•“Installing and Verifying the Neoview JDBC Type 4 Driver” (page 26)
•“Installing Perl or Python” (page 27)
2.Installation procedures:
•“Downloading the Installer” (page 27)
•“Verifying the Version of the Installer File” (page 28)
•“Running the Installer” (page 28)
3.Postinstallation procedures:
•“Verifying the Installed Software Files” (page 34)
•“Verifying the Installed Version of Neoview Script” (page 35)
•“Setting the Look and Feel of the Neoview Script Interface” (page 35)
•“Testing the Launch of Neoview Script” (page 39)
•“Installing and Verifying the Java Runtime Environment (JRE)” (page 23)
•“Installing and Verifying the Neoview JDBC Type 4 Driver” (page 26)
•“Installing Perl or Python” (page 27)
Neoview Script and the Neoview JDBC Type 4 Driver require a compatible Java version to be installed on the client workstation. The supported Java versions are:
•JRE 1.4.2
•JRE 1.4.2_01, 1.4.2_02, 1.4.2_03, 1.4.2_04, 1.4.2_05, 1.4.2_06, 1.4.2_07, 1.4.2_10, and 1.4.2_11
These Java versions are not supported:
•Versions before 1.4.2
•Version 1.5
If you are using U.S. Daylight Savings Time (DST), be aware that the start and stop dates for DSTwillchangefromthefirstSundayinApriltothesecondSundayinMarchandfromthelast Sunday in October to the first Sunday in November, starting in 2007. To avoid using incorrect times, make sure that your Java Runtime Environment uses the correct DST rules. JRE 1.4.2_11 and later versions support the new DST rules.
To install one of the supported Java versions on the client workstation, follow the instructions on the Sun Microsystems Web site:
http://java.sun.com/j2se/desktopjava/jre/index.jsp
Preinstallation Procedures |
23 |
After installing the Java version, proceed with “Verifying the Java Version” (page 24).
To display the Java version of the client workstation on the screen, enter:
java -version
For example:
C:\>java -version
java version "1.4.2_10"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_10-b03) Java HotSpot(TM) Client VM (build 1.4.2_10-b03, mixed mode)
C:\>
If the returned version is not supported or is unavailable, see:
•“Setting the PATH to a Supported Java Version on Windows” (page 24)
•“Setting the PATH to a Supported Java Version on Linux or UNIX” (page 26)
1.Right-click the My Computer icon on your desktop, and then select Properties:
2.In the System Properties dialog box, click the Advanced tab.
3.Click the Environment Variables button:
24 Installing Neoview Script
4.Under System variables, select the variable named Path, and then click Edit:
Preinstallation Procedures |
25 |
5.Place the cursor at the beginning of the Variable Value field and type the path of the Java bin directory, ending with a semicolon (;):
For example:
"C:\Program Files\Java\j2re1.4.2_10\bin";
NOTE: Check that no space is after the semicolon (;) in the path. If there are spaces in the directory name, delimit the entire directory path in double quotes (") before the semicolon.
6.Click OK.
7.Verify that the updated Path appears under System variables, and click OK.
8.In the System Properties dialog box, click OK to accept the changes.
1.Open the user profile (.profile or .bash_profile for the Bash shell) in the /home directory. For example:
vi .profile
2.In the user profile, set the PATH environment variable to include the path of the Java bin directory. For example:
export PATH=/opt/java1.4/jre/bin:$PATH
NOTE: Place the path of the Java bin directory before $PATH, and check that no space is after the colon (:) in the path. In the C shell, use the setenv command instead of export.
3.To activate the changes, either log out and log in again or execute the user profile. For example:
. .profile
Neoview Script requires a compatible JDBC driver to be installed on the client workstation. For Neoview Release 2.1, Neoview Script requires the JDBC Type 4 Driver for Neoview Release 2.1.
To install the JDBC driver:
1.Download and extract the product distribution file.
2.Set the CLASSPATH to the product JAR file.
Forinformationabouthowtoinstall,verify,andusetheJDBCdriver,seethe NeoviewJDBCType 4 Driver Programmer’s Reference or the product README.
To display the version of the JDBC driver that is already installed on the client workstation:
26 Installing Neoview Script
1.Change the directory to the lib directory, which contains the JDBC driver JAR file:
•On Windows, enter this command:
cd jdbc-installation-directory\lib
jdbc-installation-directory is the directory where you installed the JDBC driver.
•On Linux or UNIX, enter this command: cd jdbc-installation-directory/lib
jdbc-installation-directory is the directory where you installed the JDBC driver.
2.Enter this command to return version information: java -jar hpt4jdbc.jar
For example:
C:\>cd install\hpt4jdbc\lib
C:\install\hpt4jdbc\lib>java -jar hpt4jdbc.jar T1249_N24_AAK(R2.1)_11MAY07_HP_JDBCT4_2007_04_05
C:\install\hpt4jdbc\lib>
If the JAR file is inaccessible or the returned version is not supported, see “Installing the JDBC Driver” (page 26).
IfyouplantousePerlorPythonscriptswithNeoviewScript,verifythatyouhavePerlorPython installed on the client workstation. Neoview Script supports these versions of Perl and Python:
•Perl version 5.6.1
•Python version 2.3.4
If you do not have Perl or Python, download it from any open source software provider. You can perform this installation procedure anytime before or after installing Neoview Script.
NOTE: Neoview Script provides a beta version of enhanced support for Perl and Python programs. This beta version requires Jython (for Python programs) and a different version of Perl to be installed on the client workstation. For more information, see the README in the Neoview Script samples directory.
NOTE: Before following the installation procedures, you must install the Neoview JDBC Type 4 Driver on the client workstation. For more information, see “Preinstallation Procedures” (page 23).
•“Downloading the Installer” (page 27)
•“Verifying the Version of the Installer File” (page 28)
•“Running the Installer” (page 28)
TheNeoviewScriptsoftwareisavailableasadownloadableinstallerfile,hpnvsInstaller.jar, on the Software Depot site.
Installation Procedures |
27 |
1.Locateorcreateadirectoryorfolderfortheinstallerfileanywhereontheclientworkstation.
2.On the client workstation, start a Web browser and navigate to the download site: http://www.software.hp.com
3.Enter “Neoview Script” in the search box in the upper right corner of the Software Depot home page.
4.Click the HP Neoview Script link that appears in the search results.
5.Follow instructions to download HP Neoview Script, which includes the hpnvsInstaller.jar file, to the directory or folder in Step 1.
NOTE: In the File Download dialog box, make sure to select the Save or Save this file to disk option.
To display the version of the downloaded installer file:
1.Change to the directory where you downloaded the Neoview Script installer file: cd installer-directory
installer-directory is the directory where you downloaded the installer.
2.Enter this command to return version information: java -jar hpnvsInstaller.jar v
For example:
C:\>cd download
C:\download>java -jar hpnvsInstaller.jar v T0774_N24_AAC(R2.1)_11MAY07_HP_hpnvs_2007_04_12
C:\download>
NOTE: Before running the installer, you must install the Neoview JDBC Type 4 Driver on the client workstation. For more information, see “Preinstallation Procedures” (page 23).
You have a choice of running the installer from the Installer Wizard Graphical User Interface (GUI) or from the command line:
•“Installer Wizard Steps” (page 28)
•“Command-Line Installation Steps” (page 33)
NOTE: On Linux or UNIX, to run the Installer Wizard, you must have the X Window system installedontheclientworkstation.IftheclientworkstationdoesnothavetheXWindowsystem, see the “Command-Line Installation Steps” (page 33).
1.Locate the hpnvsInstaller.jar file in the folder where you downloaded the installer.
2.Verify that the hpnvsInstaller.jar file appears as an Executable JAR File. If not, skip the next two steps and go to Step 5.
3.Double-click the hpnvsInstaller.jar file icon to launch the Installer Wizard.
4.Proceed to “Using the Installer Wizard” (page 29).
28 Installing Neoview Script
5.At a command prompt, change to the directory where you downloaded the installer: cd installer-directory
installer-directory is the directory where you downloaded the installer file, hpnvsInstaller.jar.
6.Launch the Installer Wizard by entering: java -jar hpnvsInstaller.jar
7.Proceed to “Using the Installer Wizard” (page 29).
When you execute hpnvsInstaller.jar, the Installer Wizard appears:
1.To locate the JDBC driver JAR file, click Browse next to HP Neoview JDBC Type 4 Driver JAR file:
2.Select the lib folder of the JDBC driver, and then click Open:
Installation Procedures |
29 |
3.Select hpt4jdbc.jar so that it appears in the File Name box, and then click Select:
The Installer Wizard now displays the path of the JDBC driver JAR file:
30 Installing Neoview Script