www.openlinksw.com
docs.openlinksw.com

Book Home

Contents
Preface

Virtuoso Functions Guide

Administration
Aggregate Functions
Array Manipulation
BPEL APIs
Backup
Compression
Cursor
Date & Time Manipulation
Debug
Dictionary Manipulation
Encoding & Decoding
File Manipulation
Free Text
Hashing / Cryptographic
LDAP
Locale
Mail
Miscellaneous
Number
RDF data
Remote SQL Data Source
Replication
SOAP
SQL
__any_grants
close
collation_define
complete_table_name
delay
end_result
exec
exec_metadata
exec_next
exec_result
exec_result_names
exec_score
identity_value
name_part
registry_get
registry_get_all
registry_name_is_pro...
registry_remove
registry_set
result
result_names
row_count
sequence_get_all
sequence_next
sequence_remove
sequence_set
set_identity_column
set_row_count
set_user_id
signal
sinv_create_inverse
sinv_create_key_mapp...
sinv_drop_inverse
sys_stat_analyze
sys_stat_histogram
table_drop_policy
table_set_policy
username
String
Transaction
Type Mapping
UDDI
User Defined Types & The CLR
Virtuoso Java PL API
Virtuoso Server Extension Interface (VSEI)
Web Server & Internet
XML
XPATH & XQUERY

Functions Index

exec_result

Returns a result set row to the calling procedure context
any exec_result (in res_values_array any);
Description

This function returns a result set row to the calling procedure's context, whether it is the client, exec function or a procedure view). The row's values are the elements of the supplied res_values_array vector.

Parameters
res_values_array – This parameter can be one of two things:
  • a vector of strings (like vector('cola', 'colbb')). When used that way it makes columns named 'cola' and 'colb' with type ANY and precision 256
  • an array with the same format as the 0th element of the metadata returned by exec() and rexec(), which contains all the type information and can be used directly.
Return Types

The row's values are the elements of the supplied res_values_array vector. For example: exec_result (vector (1, 'a')) will return a row of two columns: 1 and 'a'. This is similar to the result() function, but it uses an array instead of parameter list

Examples
Result set rows
create procedure XX1 ()
{
  declare meta, _dt any;
  declare inx integer;
  exec ('select U_ID, U_NAME from SYS_USERS', null, null, null, 0, meta, _dt);
  inx := 0;

  exec_result_names (meta[0]);
  while (inx < length (_dt))
    {
      exec_result (_dt[inx]);
      inx := inx + 1;
    }
};

See Also

exec()

rexec()

exec_result_names()

result_names()