SAP ABAP Class CL_SQL_CONNECTION (Database Connection)
Hierarchy
SAP_BASIS (Software Component) SAP Basis Component
   BC-DB-DBI (Application Component) DB-Independent Database Interface
     SDB_ADBC (Package) ABAP Database Call Interface (Dynamic SQL)
Properties
Class CL_SQL_CONNECTION  
Short Description Database Connection    
Super Class    
Instantiability of a Class 2  Public 
Final    
General Data
Message Class    
Program status     
Category 0   
Package SDB_ADBC   ABAP Database Call Interface (Dynamic SQL) 
Created 20001208   SAP 
Last change 20130531   SAP 
Shared Memory-enabled    
Fixed point arithmetic    
Unicode checks active    
Forward declarations
Class CL_SQL_CONNECTION has no forward declaration.
Interfaces
Class CL_SQL_CONNECTION has no interface implemented.
Friends
# Friend Modeled only Created on Description
1 CL_SQL_RESULT_SET 20001208 Resulting Set of an SQL Query
2 CL_SQL_STATEMENT 20001208 SQL statement
Attributes
# Attribute Level Visibility Read only Typing Associated Type Initial Value Description Created on
1 CON_DA Instance attribute Private Type reference (TYPE) L_CONDA_T Connection Descriptor Area 20001208
2 CON_NAME Instance attribute Private Type reference (TYPE) DBCON_NAME Logical name for a database connection 20001208
3 C_DEFAULT_CONNECTION Constant Public Type reference (TYPE) DBCON-CON_NAME 'DEFAULT' Logical Name of the Default Connection 20030702
4 C_FCODE_COMMIT Constant Private Type reference (TYPE) L_FCODE_T 'CT' Function Code for "COMMIT" 20030703
5 C_FCODE_CONNECT Constant Private Type reference (TYPE) L_FCODE_T 'CO' Function Code for "CONNECT" 20030703
6 C_FCODE_DEFAULT_CONNECTION Constant Private Type reference (TYPE) L_FCODE_T 'DC' Function Code for "GET DEFAULT CONNECTION" 20030703
7 C_FCODE_DISCONNECT Constant Private Type reference (TYPE) L_FCODE_T 'DI' Function Code for "DISCONNECT" 20030703
8 C_FCODE_GET_CONNECTION Constant Private Type reference (TYPE) L_FCODE_T 'GC' Function Code for "GET CONNECTION" 20100625
9 C_FCODE_PING Constant Private Type reference (TYPE) L_FCODE_T 'PG' Function Code for "PING" 20030703
10 C_FCODE_ROLLBACK Constant Private Type reference (TYPE) L_FCODE_T 'RB' Function Code for "ROLLBACK" 20030703
11 DBMS Instance attribute Private Type reference (TYPE) DBCON_DBMS Database System 20010518
12 IS_CONNECTED Instance attribute Private Type reference (TYPE) FLAG SPACE Database Connection Open? 20030702
13 IS_SHARABLE Instance attribute Private Type reference (TYPE) FLAG SPACE General Flag 20100625
14 KERNEL_DEFAULT_NAME Instance attribute Private Type reference (TYPE) DBCON-CON_NAME 'R/3' Name Used in the Kernel for the Default Connection 20030702
Methods
# Method Level Visibility Method type Description Created on
1 CLOSE Instance method Public Method Closes an Open Database Connection 20001208
2 COMMIT Instance method Public Method Commit the Running Database Transaction 20001208
3 CONSTRUCTOR Instance method Public Constructor Constructor 20020219
4 CREATE_STATEMENT Instance method Public Method Creates a Statement Object for this Database Connection 20001208
5 GET_CONNECTION Static method Public Method Opens a Connection to a Database 20001208
6 GET_CON_NAME Instance method Public Method Returns the Connection Name Entered in the DBCON 20010703
7 GET_DBMS Instance method Public Method Returns the Type of the Database System 20020219
8 GET_METADATA Instance method Public Method Creates a Metadata Object for This Connection 20010518
9 IS_CLOSED Instance method Public Method Checks Whether the Connection is Closed 20010522
10 PING Instance method Public Method Checks Whether the Current Database Connection Still Exists 20030702
11 PREPARE_STATEMENT Instance method Public Method Creates a Prepared Statement Obect 20001208
12 ROLLBACK Instance method Public Method Rollback of the Running Database Transaction 20001208
13 VALIDATE Instance method Private Method Checks the validity of this connection object 20100625
Events
Class CL_SQL_CONNECTION has no event.
Types
# Type Visibility Typing Associated Type Description Created on Type Source
1 L_CONDA_T Private See coding Connection Descriptor Area in the Kernel 20001208
2 L_FCODE_T Private See coding 20030703
Method Signatures

Method CLOSE Signature

Method CLOSE on class CL_SQL_CONNECTION has no parameter.
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20001208

Method COMMIT Signature

Method COMMIT on class CL_SQL_CONNECTION has no parameter.
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20001208

Method CONSTRUCTOR Signature

Method CONSTRUCTOR on class CL_SQL_CONNECTION has no parameter.
Method CONSTRUCTOR on class CL_SQL_CONNECTION has no exception.

Method CREATE_STATEMENT Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning STMT_REF Value transfer Object reference (TYPE REF TO) CL_SQL_STATEMENT Referenz auf eine SQL Statement 20001208
2 Importing TAB_NAME_FOR_TRACE Call by reference Type reference (TYPE) TABNAME Tabellenname 20120608

Method CREATE_STATEMENT on class CL_SQL_CONNECTION has no exception.

Method GET_CONNECTION Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing CON_NAME Call by reference Type reference (TYPE) DBCON_NAME SPACE Einstelliges Kennzeichen 20001208
2 Returning CON_REF Value transfer Object reference (TYPE REF TO) CL_SQL_CONNECTION Connection-Objekt 20001208
3 Importing SHARABLE Value transfer Type reference (TYPE) FLAG SPACE allgemeines flag 20100625
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20001208

Method GET_CON_NAME Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning CON_NAME Value transfer Type reference (TYPE) DBCON_NAME Logischer Name einer Datenbankverbindung 20010703

Method GET_CON_NAME on class CL_SQL_CONNECTION has no exception.

Method GET_DBMS Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning DBMS Value transfer Type reference (TYPE) DBCON-DBMS Datenbanksystem 20020219

Method GET_DBMS on class CL_SQL_CONNECTION has no exception.

Method GET_METADATA Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning MD_REF Value transfer Object reference (TYPE REF TO) CL_SQL_METADATA Methoden zur Beschreibung von DB-Objekten 20010518
# Exception Resumable Description Created on
1 CX_PARAMETER_INVALID Oberklasse für Parameterfehler 20010521

Method IS_CLOSED Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning IS_CLOSED Value transfer Type reference (TYPE) FLAG 'X', falls die Verbindung geschlossen ist 20010522

Method IS_CLOSED on class CL_SQL_CONNECTION has no exception.

Method PING Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning PING_OK Value transfer Type reference (TYPE) FLAG Verbindung ok? 20030702
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20030702

Method PREPARE_STATEMENT Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning PREPSTMT_REF Value transfer Object reference (TYPE REF TO) CL_SQL_PREPARED_STATEMENT Ein präpariertes SQL Statement 20001208
2 Importing STATEMENT Call by reference Type reference (TYPE) STRING Das zu präparierende SQL Statement 20001208
3 Importing TAB_NAME_FOR_TRACE Call by reference Type reference (TYPE) TABNAME Tabellenname 20120608
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20001211

Method ROLLBACK Signature

Method ROLLBACK on class CL_SQL_CONNECTION has no parameter.
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20001208

Method VALIDATE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing CON_CHANGE_NOT_ALLOWED Call by reference Type reference (TYPE) FLAG SPACE allgemeines flag 20100625
# Exception Resumable Description Created on
1 CX_SQL_EXCEPTION Ausnahmeklasse für SQL Fehler 20100625
History
Last changed by/on SAP  20130531 
SAP Release Created in 610