INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

title: "Represents the notion of session, database or query status"
project: "Visual Eiffel"
revision: "$Revision: 1.1 $"
copyright: "Copyright (C) 1996-2005 Object Tools Group"
license: "http://visual-eiffel.com/license"
cluster: dale
class ODBC_STATUS
inherit

DALE_SERVER
end
creation {SESSION}

attach_to_session
creation {DATABASE}

attach_to_database
creation {SIMPLE_QUERY}

attach_to_query
creation {SQL_SCRIPT}

attach_to_sql_script
feature -- Attribute

errs: LIST_ [ODBC_ERROR_DESCRIPTION]
feature -- Command

forget_errors
-- forget all errors are accumulated to present moment
require
attached: is_attached

print_errors
-- print all errors
require
attached: is_attached

errors_to_string: STRING
-- convert all errors to string
require
attached: is_attached

first_error_code: STRING
-- convert first error code to string
require
attached: is_attached

first_error: STRING
-- convert first error to string
require
attached: is_attached
feature -- Queries

retcode: INTEGER
-- returns result code after the latter operation

success: BOOLEAN
-- returns True if no errors were found
require
attached: is_attached

success_with_info: BOOLEAN
-- returns True if no errors were found but there is
-- some additional information
require
attached: is_attached

ok: BOOLEAN
-- returns True if no errors were found but may be
-- some additional information.
require
attached: is_attached

error: BOOLEAN
-- returns True if error(s) occured or invalid handler was used
require
attached: is_attached

invalid_handler: BOOLEAN
-- returns True if an invalid handler was used
require
attached: is_attached

still_executing: BOOLEAN
-- returns True if last operation hasn't finished yet
require
attached: is_attached

need_data: BOOLEAN
-- returns True if an additional data is needed
require
attached: is_attached

no_data_found: BOOLEAN
-- returns True if no data found
require
attached: is_attached
feature -- * Advanced attributes

descend: BOOLEAN
feature -- * Advanced queries

is_attached: BOOLEAN
-- is this status attached to an ODBC element?

retrieve_errors: LIST_ [ODBC_ERROR_DESCRIPTION]
-- returns list of error descriptions
require
attached: is_attached

find_error (s: STRING): ODBC_ERROR_DESCRIPTION
-- returns a description of the error associated to the specified
-- SQL state or Void if not found
require
attached: is_attached
valid_sql_state: valid_sql_state (s)
feature -- Settings

set_descend (f: BOOLEAN)
-- ...
require
attached: is_attached

set_errors_list
-- ...
feature -- Validations

valid_sql_state (s: STRING): BOOLEAN
-- returns True if the specified SQL state is valid
feature {SESSION}

attach_to_session (s: SESSION)
-- creation procedure; attaches status to the specified session
require
valid_session: s /= void and then s.is_attached
feature {DATABASE}

attach_to_database (db: DATABASE)
-- creation procedure; attaches status to the specified database
require
valid_database: db /= void and then db.is_attached
feature {SIMPLE_QUERY}

attach_to_query (q: SIMPLE_QUERY)
-- creation procedure; attaches status to the specified query
require
valid_query: q /= void and then q.is_attached
feature {SQL_SCRIPT}

attach_to_sql_script (q: SQL_SCRIPT)
-- creation procedure; attaches status to the specified SQL script
end -- class ODBC_STATUS

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES