SparkseePython  6.0.2
Public Member Functions | List of all members
sparksee.ResultSet Class Reference

ResultSet class. More...

Public Member Functions

def rewind (self)
 Positions the cursor before the first row.
 
def get_column_data_type (self, index)
 Gets the datatype for the given column. More...
 
def get_column (self, index)
 Gets the value for the given column. More...
 
def get_num_columns (self)
 Gets the number of columns. More...
 
def get_column_name (self, index)
 Gets the name for the given column. More...
 
def next (self)
 Fetches the next row. More...
 
def get_j_s_o_n (self, rows)
 Returns rows in JSON format. More...
 
def get_column (self, index, value)
 Gets the value for the given column. More...
 
def get_column_index (self, name)
 Gets the column index for the given column name. More...
 
def is_closed (self)
 Gets if the ResultSet instance has been closed or not. More...
 

Detailed Description

ResultSet class.

Author
Sparsity Technologies http://www.sparsity-technologies.com

Member Function Documentation

def sparksee.ResultSet.get_column (   self,
  index 
)

Gets the value for the given column.

QueryExceptionIf a database access error occurs.

Parameters
index[in] Column index.
Returns
The Value of the given column.

Referenced by sparksee.ResultSet.get_column().

def sparksee.ResultSet.get_column (   self,
  index,
  value 
)

Gets the value for the given column.

QueryExceptionIf a database access error occurs.

Parameters
index[in] Column index.
value[in|out] Value.

References sparksee.ResultSet.get_column().

def sparksee.ResultSet.get_column_data_type (   self,
  index 
)

Gets the datatype for the given column.

Parameters
index[in] Column index.
Returns
DataType for the given column.
def sparksee.ResultSet.get_column_index (   self,
  name 
)

Gets the column index for the given column name.

Parameters
name[in] Column name.
Returns
Column index.
def sparksee.ResultSet.get_column_name (   self,
  index 
)

Gets the name for the given column.

Parameters
index[in] Column index.
Returns
Column name.
def sparksee.ResultSet.get_j_s_o_n (   self,
  rows 
)

Returns rows in JSON format.

Rows are returned from the current position.

Parameters
rows[in] Maximum number of rows
Returns
JSON representation of the next <rows> rows in the resultset
def sparksee.ResultSet.get_num_columns (   self)

Gets the number of columns.

Columns are in the range [0...COLUMNS).

Returns
The number of columns.
def sparksee.ResultSet.is_closed (   self)

Gets if the ResultSet instance has been closed or not.

See also
#close()
Returns
TRUE if the ResultSet instance has been closed, FALSE otherwise.
def sparksee.ResultSet.next (   self)

Fetches the next row.

A ResultSet cursor is initially positioned before the first row; the first call to the method "Next" makes the first row the current row; the second call makes the second row the current row, and so on.

QueryExceptionIf a database access error occurs.

Returns
TRUE if the next row has been successfully fetched, FALSE otherwise.