HP NEOVIEW 544530-001 Manual do Utilizador

Consulte online ou descarregue Manual do Utilizador para Software HP NEOVIEW 544530-001. HP NEOVIEW 544530-001 User's Manual Manual do Utilizador

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 142
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes

Resumo do Conteúdo

Página 1 - HP Neoview Script Guide

HP Neoview Script GuideHP Part Number: 544530-001Published: May 2007Edition: HP Neoview Release 2.1

Página 3 - Table of Contents

SyntaxRESET PARAM [param-name]param-nameis the name of the parameter for which you specified a value. Parameter namesare case-sensitive. For example,

Página 4 - 4 Table of Contents

-------------------- 62 --- 1 row(s) selected.SQL>SAVEHIST CommandThe SAVEHIST command saves the session history in a user-specif

Página 5 - Table of Contents 5

to use for separating columns in each row of the results. The default delimiter is “ ”(whitespace).SyntaxSET COLSEP [separator] ConsiderationsIn the N

Página 6 - 6 Table of Contents

--- SQL operation complete.SQL> INSERT INTO COURSE1 VALUES+> ('C11', 'INTRO TO CS','FOR ROOKIES',3, 100,'CI

Página 7 - Table of Contents 7

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• If you execut

Página 8 - 8 Table of Contents

<td>STEVENS SUPPLY</td> <td>700510</td> <td>2003-06-01</td></tr><tr> <td>3333</td>

Página 9 - Table of Contents 9

<Results><Query> <![CDATA[select * from author;]]></Query><rowid="1"> <AUTHORID>91111</AUTHORID>

Página 10

Examples• This SET LIST_COUNT command specifies that the number of rows to be displayed bySELECT statements is five:SQL>set list_count 5SQL>sele

Página 11 - List of Figures

The EXECUTE statement substitutes parameter values for the parameters in the preparedstatement. For more information about EXECUTE, see the Neoview SQ

Página 12

NOTE: The names of the named parameters, ?sal and ?job, in the SELECT statementare identical to the parameter names, sal and job, in the SET PARAM com

Página 13 - List of Tables

List of Figures1-1 Neoview Script Within a Neoview Platform Network...2111

Página 14

SQL>• This command displays the session user name for the prompt:SQL>set prompt %user>dba1>• This command displays the operating mode of t

Página 15 - About This Document

%DATASOURCE displays the session data source as the prompt.Considerations• In the Neoview Script interface, you must enter the command on one line. Th

Página 16 - Notation Conventions

SET SQLTERMINATOR CommandThe SET SQLTERMINATOR command sets the SQL statement terminator of the current session.The default is a semicolon (;).SyntaxS

Página 17 - Related Documentation

Starting with the R2.1 release, the default is a 24–hour military style display. The additionalargument of 12h allows the time to be displayed in a 12

Página 18 - Neoview Support Library

SyntaxSHOW COLSEP ConsiderationsIn the Neoview Script interface, you must enter the command on one line. The command doesnot require an SQL terminator

Página 19 - HP Encourages Your Comments

Examples• This command shows that the idle timeout value of the session is 30 minutes, which is thedefault:SQL>show idletimeoutIDLETIMEOUT 30 min(s

Página 20

ExamplesThis command displays the value set for the markup option:SQL>show markupMARKUP RAWSHOW MODE CommandThe SHOW MODE command displays the oper

Página 21

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• If you do not

Página 22

quotes. To look for similar values, specify only part of the charactersof wild-card-pattern combined with these wild-card characters:Use a percent sig

Página 23 - 2 Installing Neoview Script

SyntaxSHOW PARAMConsiderations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator

Página 25 - Preinstallation Procedures 25

Examples• This SHOW PREPARED command shows all the prepared statements, by default:SQL>show preparedS1 select * from t1S2 select * fr

Página 26 - Verifying the JDBC Driver

wild-card-patternis a character string used to search for and display schemas withnames that match the character string. wild-card-pattern matchesan u

Página 27 - Installation Procedures

SHOW SESSION CommandSHOW SESSION or SESSION displays attributes of the current Neoview Script session. You canalso use the ENV command to perform the

Página 28 - Running the Installer

Current setting (on or off) of the elapsed time. By default, the elapsed time is off.For more information, see “Displaying the Elapsed Time” (page 54)

Página 29 - Installation Procedures 29

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• You can execu

Página 30 - 30 Installing Neoview Script

look for similar values, specify only part of the characters ofwild-card-pattern combined with these wild-card characters:Use a percent sign to indica

Página 31 - Installation Procedures 31

SyntaxSHOW TABLE {table-name | materialized-view-name}, { INDEXES | MVS | SYNONYMS |ALL}table-name is: [schema-name.]table-nametable-namespecifies

Página 32 - 32 Installing Neoview Script

Index 2 :XEMPDEPT-----------------DEPTNUM ASC Other No 0 1Index 3 :XEMPNAME1-----------------LAST_NAME

Página 33 - Installation Procedures 33

wild-card-patternis a character string used to search for and display tables with namesthat match the character string. wild-card-pattern matches anup

Página 34 - Postinstallation Procedures

SyntaxSHOW TIMEConsiderationsIn the Neoview Script interface, you must enter the command on one line. The command doesnot require an SQL terminator.Ex

Página 35 - SQL>

List of Tables2-1 Locations of Neoview Script Software Files...3413

Página 36 - Supported Look-and-Feel Types

for similar values, specify only part of the characters ofwild-card-pattern combined with these wild-card characters:Use a percent sign to indicate ze

Página 37

ONstarts the logging process and records information in the sqlspool.lstfile in the Neoview Script bin directory.ON CLEARinstructs Neoview Script to c

Página 38 - -DhpnvsLF=SQLPlus

ConsiderationsIn the Neoview Script interface, you must enter the command on one line. The command doesnot require an SQL terminator.ExampleThis comma

Página 39 - . .profile

B Supported SQL StatementsNeoview Script supports these SQL statements, SQL utilities, and other SQL-related commands.For more information about these

Página 40 - 40 Installing Neoview Script

DescriptionSQL StatementInserts rows of data into a table or view.INSERTLocks the specified table (or underlying tables of a view)and its associated i

Página 41

C Connectivity Service CommandsNeoview Script supports connectivity service commands in the Neoview Script interface inconnectivity service (CS) mode.

Página 42

Available servers for this service on this data source(registered minus connected servers)AvailSrvrCntNumber of idle servers to start when data source

Página 43

IndexSymbols-DhpnvsLF property, 35-dsn parameter, 46-h parameter, 46-host parameter, 46-no connect parameter, 47-noconnectexamples of, 50-p parameter,

Página 44 - Setting the PATH of hpnvs.sh

INFO DS command, 135INSERT statementdescription of, 134example of, 54Installation proceduresdownloading the Neoview Script installer file, 27testing t

Página 45 - Default Login

description of, 134examples of, 75, 76Port number, default, 45PREPARE statementdescription of, 134examples of, 60Product banner, 51Promptscontinuation

Página 47

syntax of, 127SHOW TIME command, 128SHOW TIMING command, 129SHOW VIEWS commandexample of, 57syntax of, 129SPOOL commandexamples of, 64syntax of, 130Sp

Página 50 - SQL>quit

About This DocumentThis manual describes how to use the Neoview Script command-line interface on a clientworkstation to manage a database on a Neoview

Página 51 - Interface

Describes how to run Neoview Script from Perl or Python.Chapter 6: Running NeoviewScript From Perl or PythonProvides syntax, considerations, and examp

Página 52 - Case Sensitivity

| Vertical Line A vertical line separates alternatives in a horizontal list that is enclosedin brackets or braces. For example:{expression | NULL}… El

Página 53

Neoview Customer LibraryThis manual is part of the Neoview customer library:• AdministrationInformation about how to load and manage the Neoview datab

Página 54 - Displaying the Elapsed Time

Installation and replacement procedures.Neoview Hardware Installation and SupportGuideInformation on managing and configuring Dashboard from theDashbo

Página 55

© Copyright 2007 Hewlett-Packard Development Company, L.P.Legal NoticeConfidential computer software. Valid license from HP required for possession, u

Página 57 - Showing the Views in a Schema

1 Introduction to Neoview ScriptNeoview Script is a command-line interface that you download and install on a client workstationthat has the Neoview J

Página 59 - Running SQL Statements

2 Installing Neoview ScriptNOTE: If you are manually installing Neoview Script on a Linux platform that has the Neoviewdata loader installed, use the

Página 60 - Preparing an SQL Statement

After installing the Java version, proceed with “Verifying the Java Version” (page 24).Verifying the Java VersionTo display the Java version of the cl

Página 61 - Resetting the Parameters

4. Under System variables, select the variable named Path, and then click Edit:Preinstallation Procedures 25

Página 62

5. Place the cursor at the beginning of the Variable Value field and type the path of the Javabin directory, ending with a semicolon (;):For example:&

Página 63 - Logging Output

1. Change the directory to the lib directory, which contains the JDBC driver JAR file:• On Windows, enter this command:cd jdbc-installation-directory\

Página 64 - Stopping the Logging Process

1. Locate or create a directory or folder for the installer file anywhere on the client workstation.2. On the client workstation, start a Web browser

Página 65 - Logging Output 65

5. At a command prompt, change to the directory where you downloaded the installer:cd installer-directoryinstaller-directory is the directory where yo

Página 66

Table of ContentsAbout This Document...15Intended

Página 67 - Creating a Script File

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 JA

Página 68 - Running a Script File

4. To find an installation location for Neoview Script, click Browse next to HP Neoview Scriptinstallation directory:5. Select the folder where you wa

Página 69 - Running Scripts in Parallel

The Installer Wizard displays the directory where the Neoview Script will be installed.6. Click Install to start the installation:32 Installing Neovie

Página 70

The Installation Status dialog box appears on the screen, indicating how many files areinstalled in the installation directory:The number of files tha

Página 71

4. Enter an existing directory where you would like to install Neoview Script:HP Neoview Script--------------------------------------Enter the install

Página 72

Table 2-1 Locations of Neoview Script Software Files (continued)DescriptionFilesDirectoryBeta version of sample Perl program1sample-beta.plBeta versio

Página 73

execute in the Neoview Script interface. Each look-and-feel type accepts all the SQL statements,commands, and syntax that Neoview Script currently sup

Página 74

If you do not set a look and feel, the default is Neoview SQL.Setting the Look and Feel at a Command-Line PromptTo set the _JAVA_OPTIONS environment v

Página 75

3. If _JAVA_OPTIONS does not appear among the environment variables, click New underSystem or User variables. If _JAVA_OPTIONS already exists, click E

Página 76

6. In the System Properties dialog box, click OK to accept the changes.To return to the default look and feel, Neoview SQL, set the -DhpnvsLF property

Página 77

Presetting the Optional Launch Parameters...45Logging In to the Datab

Página 78 - >python example.py

2. If you cannot connect to the database, verify that:1. The database platform is available and running, the port number is correct for thedatabase pl

Página 79

3 Launching the Neoview Script InterfaceThis chapter describes how to launch the Neoview Script interface from the Windows, Linux, orUNIX environment:

Página 80

2. Type the location of hpnvs.cmd within double quotes (“) or click Browse to locate that file,and then click Next:For the location of the Neoview Scr

Página 81 - @ Command

4. If desired, specify optional launch parameters for the shortcut:a. Right-click the shortcut icon and select Properties:b. Click the Shortcut tab.c.

Página 82 - / Command

For more information, see “Using Optional Launch Parameters” (page 46).d. Click OK.5. To launch Neoview Script, double-click the shortcut icon.The Neo

Página 83 - CONNECT Command

hpnvs-installation-directory is the directory where you installed the NeoviewScript software files. For more information, see Table 2-1 (page 34). Che

Página 84 - DISCONNECT Command

3. Enter your password.4. Enter the name of a data source that is available and running (that is, started).If you do not enter a data source, Neoview

Página 85 - ENV Command

DescriptionLaunch ParameterSpecifies that an SQL statement or a Neoview Scriptinterface command be run when launching the NeoviewScript interface. You

Página 86 - EXIT Command

Although you can run any of the Neoview Script interface commands with -q or -sql, the @,OBEY, and PRUN commands are the most useful. For a list of su

Página 87 - FC Command

DISCONNECT command. To quit the interface immediately after executing a script file, includethe EXIT, QUIT, or DISCONNECT command at the end of the sc

Página 88

SPOOL log-file or LOG log-file Command...64Using the CLEAR Option...

Página 89 - FC Command 89

Example of Launching Neoview Script File With -noconnect• On Windows, in the Command Prompt window, enter:cd hpnvs-installation-directory\nvscript\bin

Página 90 - HISTORY Command

4 Running Commands Interactively in the Neoview ScriptInterfaceAfter launching the Neoview Script interface, you can run SQL statements and Neoview Sc

Página 91 - LOG Command

You can continue any SQL statement over multiple lines, breaking that statement at any pointexcept within a word, a numeric literal, or a multicharact

Página 92 - MODE Command

SCHEMA USRSERVER neo0101.acme.com:18650SQLTERMINATOR ;TIME OFFTIMING OFFUSER role.dbaSQL>For more info

Página 93 - OBEY Command

20:32:26 SQL ENTER>set time offSQL ENTER>For more information, see the “SET TIME Command” (page 112).Setting and Showing the SQL TerminatorThe S

Página 94

SQL>For more information, see the “SET TIMING Command” (page 113).Setting and Showing the Current SchemaBy default, the schema of the session is US

Página 95 - PRUN Command

• “Showing the Views in a Schema” (page 57)• “Showing the Synonyms in a Schema” (page 57)Showing the SchemasThe SHOW SCHEMAS command displays the sche

Página 96

SQL>For more information, see the “SHOW TABLE Command” (page 125).Showing the Views in a SchemaThe SHOW VIEWS command displays the views that exist

Página 97 - QUIT Command

For more information, see the “SHOW SYNONYMS Command” (page 124).Displaying Executed CommandsTo display commands that were recently executed in the Ne

Página 98 - REPEAT Command

Running SQL StatementsIn the Neoview Script interface, you can run SQL statements interactively. For a list of SQLstatements that you can run interact

Página 100 - RUN Command

SQL>For more information, see the “/ Command” (page 82), “RUN Command” (page 100), or “REPEATCommand” (page 98).Preparing and Executing SQL Stateme

Página 101 - SET COLSEP Command

Setting ParametersIn a Neoview session, you can set a parameter of an SQL statement (either prepared or not) byusing the SET PARAM command.NOTE: The p

Página 102 - SET HISTOPT Command

dn 1500sal 80000.00SQL>For the syntax of the RESET PARAM command, see the “RESET PARAM Command” (page 99).Executing a Prepared SQL StatementTo exec

Página 103 - SET IDLETIMEOUT Command

TED MCDONALD 2000 PETER SMITH 3300 MARK FOLEY 4000 HEIDI

Página 104 - SET MARKUP Command

hpnvs-installation-directory is the directory where you installed the NeoviewScript software files. For more information, see Table 2-1 (page 34).• On

Página 105 - SET MARKUP Command 105

For information about error messages that might appear in the log file, see the Neoview MessagesManual.Logging Output 65

Página 107 - SET PARAM Command

5 Running Scripts in the Neoview Script InterfaceIn the Neoview Script interface, you can run script files.• “Creating a Script File” (page 67)• “Runn

Página 108 - Examples

the section name in the @ or OBEY command. For more information, see the“@ Command”(page 81) or the “OBEY Command” (page 93).Example of a Script FileT

Página 109 - SET PROMPT Command

NOTE: If the script file is outside the directory of the hpnvs.cmd or hpnvs.sh file (by default,the Neoview Script bin directory), you must specify th

Página 110 - SET SQLPROMPT Command

Considerations...100Exampl

Página 111

NOTE: Starting with the 2.1 release, the PRUN command can be run in non-interactive mode.The PRUN command now allows options to be specified on the co

Página 112 - SET TIME Command

6 Running Neoview Script From Perl or PythonYou can execute an SQL statement in Perl or Python by invoking the Neoview Script Perl orPython wrapper sc

Página 113 - SHOW COLSEP Command

set HPNVS_PASSWORD=passwordset HPNVS_DATASOURCE=data-source-nameSetting Login Environment Variables in the System Properties1. Right-click the My Comp

Página 114 - SHOW IDLETIMEOUT Command

4. In the Environment Variables dialog box, click New under System or User variables,whichever you prefer.5. In the New User Variable dialog box, type

Página 115 - SHOW MARKUP Command

export HPNVS_SERVER=host-name:port-numberexport HPNVS_USER=user-nameexport HPNVS_PASSWORD=passwordexport HPNVS_DATASOURCE=data-source-nameAt each comm

Página 116 - SHOW MVGROUPS Command

You can pass only one SQL statement at a time on the Perl or Python command line. The SQLstatement must:• Be enclosed in double quotes (") withou

Página 117 - SHOW MVS Command

For example:>cd /usr/local/hp/nvscript/bin>perl hpnvs.pl "POPULATE INDEX neo.persnl.xempname >ON neo.persnl.employee"• On the Pytho

Página 118 - SHOW PARAM Command

#-----Reorganize the table --------------------------------------------------$status=`perl /usr/local/hp/nvscript/bin/hpnvs.pl "$reorgtable"

Página 119 - SHOW PREPARED Command

hpnvs-installation-directory is the directory where you installed the NeoviewScript software files. For more information, see Table 2-1 (page 34).To r

Página 120 - SHOW SCHEMAS Command

A Neoview Script Interface CommandsNeoview Script supports these commands in the Neoview Script interface or in script files thatyou run in the Neovie

Página 121

Syntax...114

Página 122 - SHOW SESSION Command

SyntaxDescriptionCommandSee the “RUN Command” (page 100).Runs the previously executed SQLstatement.RUNSee the “SAVEHIST Command”(page 101).Saves the s

Página 123 - SHOW SQLPROMPT Command

SyntaxDescriptionCommandSee the “SHOW MVGROUPSCommand” (page 116).Displays all or a set of thematerialized view groups in thecurrent schema of the Neo

Página 124 - SHOW SYNONYMS Command

script-fileis the name of an ASCII text file that contains SQL statements, NeoviewScript interface commands, and comments. If the script file exists o

Página 125 - SHOW TABLE Command

SQL>/(EXPR) -------------------- 62 --- 1 row(s) selected.SQL>CLEAR CommandThe CLEAR command clears the interfac

Página 126

If Neoview Script was invoked with the -noconnect launch parameter, Neoview Script promptsyou for the values.Currently, none of the commands work with

Página 127 - SHOW TABLES Command

ENV CommandENV displays attributes of the current Neoview Script session. You can also use the SESSIONand SHOW SESSION commands to perform the same fu

Página 128 - SHOW TIME Command

Current setting (on or off) of the elapsed time. By default, the elapsed time is off.For more information, see “Displaying the Elapsed Time” (page 54)

Página 129 - SHOW VIEWS Command

error-codeis an integer that represents an error condition of the previously executedcommand. If the previously executed command returns this error co

Página 130 - SPOOL Command

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• You cannot ex

Página 131 - VERSION Command

SQL>select * from persnl.employee;...Pressing Enter executes the corrected SELECT statement.• Correct an SQL statement that you entered incorrectl

Página 132

SHOW SQLTERMINATOR Command...124Syntax...

Página 133 - B Supported SQL Statements

SQL>where jobcode=450;...Pressing Enter lists the employee number and last names of all employees whose job codeis 450:EMPNUM LAST_NAME

Página 134

SyntaxHISTORY [number]numberis the number of commands to display. The default number is 10. The maximumnumber is 100.Considerations• In the Neoview Sc

Página 135 - INFO DS Command

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• Use a unique

Página 136

• MODE and SHOW MODE• SET COLSEP and SHOW COLSEP• SET HISTOPT and SHOW HISTOPT• SET IDLETIMEOUT and SHOW IDLETIMEOUT• SET MARKUP and SHOW MARKUP• SET

Página 137

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• Put a space b

Página 138 - 138 Index

+> CNO VARCHAR(3) NOT NULL,+> CNAME VARCHAR(22) NOT NULL,+> CDESCP VARCHAR(25) NOT NULL, +> CRED INT,+

Página 139

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• You can execu

Página 140 - 140 Index

Total connections ...5 Total connection failures...0You can execute this command only in SQL mode.

Página 141

log c:\errorCode.logselect * from employee;quit if errorcode=4082log offThese results are logged when error code 4082 occurs:SQL>select * from empl

Página 142

Considerations• In the Neoview Script interface, you must enter the command on one line. The commanddoes not require an SQL terminator.• To reexecute

Comentários a estes Manuais

Sem comentários