IBM PureData System for Analytics, Version 7.1

SELECT

Use the SELECT command to start a stored procedure on a IBM® Netezza® host.

Note: The CALL, EXEC, EXECUTE, EXECUTE PROCEDURE, and SELECT commands are identical in their behavior, inputs, and outputs. The different commands provide compatibility with other procedural language invocation methods.

Synopsis

SELECT procedure_name(arguments)

Inputs

The SELECT command takes the following inputs:
Table 1. SELECT inputs
Input Description
procedure_name The name of the stored procedure that you want to start.
arguments Specifies a list of constant or literal arguments to the procedure. The arguments might be results of functions, if the functions take only constant/literal arguments as well.
You cannot specify a FROM clause.

Outputs

The SELECT command has the following outputs:

Table 2. SELECT outputs
Output Description
ERROR: EXECUTE PROC: Permission denied. This error indicates that the current user account does not have Execute permission for the stored procedure.
ERROR: Function 'NAME(ARGS)' does not exist

Unable to identify a function that satisfies the argument types

You might need to add explicit typecasts

This message indicates that the user entered incorrect arguments for the stored procedure. A procedure of that name exists, but it is expecting different input arguments.

Description

Privileges required
To start a stored procedure, you must meet one of the following criteria:
  • You have the Execute privilege on the PROCEDURE object.
  • You have the Execute privilege on the specific procedure.
  • You own the procedure.
  • You are the database admin user.
  • You own the current database.

Usage

The following examples provide some sample usage:
MYDB(USER)=> SELECT updateacct();
MYDB(USER)=> SELECT inventorysearch(umbrellas);


Feedback | Copyright IBM Corporation 2014 | Last updated: 2014-02-28