IBM Books

Administrative API Reference


DB2 APIs

The following table lists the APIs grouped by functional category:

Table 1. DB2 APIs
API Description Sample Code a INCLUDE File b
Database Manager Control
sqlepstart - Start Database Manager makeapi, dbstart sqlenv
sqlepstp - Stop Database Manager makeapi, dbstop sqlenv
sqlfxsys - Get Database Manager Configuration dbmconf sqlutil
sqlfdsys - Get Database Manager Configuration Defaults d_dbmcon sqlutil
sqlfrsys - Reset Database Manager Configuration dbmconf sqlutil
sqlfusys - Update Database Manager Configuration dbmconf sqlutil
sqlesdeg - Set Runtime Degree setrundg sqlenv
Database Control
db2DatabaseRestart - Restart Database n/a db2ApiDf
sqlecrea - Create Database dbconf sqlenv
sqlecran - Create Database at Node n/a sqlenv
sqledrpd - Drop Database dbconf sqlenv
sqledpan - Drop Database at Node n/a sqlenv
sqlemgdb - Migrate Database migrate sqlenv
sqlxphqr - List Indoubt Transactions n/a sqlxa
sqle_activate_db - Activate Database n/a sqlenv
sqle_deactivate_db - Deactivate Database n/a sqlenv
sqlcspqy - List DRDA Indoubt Transactions n/a sqlxa
Database Directory Management
sqlecadb - Catalog Database dbcat sqlenv
sqleuncd - Uncatalog Database dbcat sqlenv
sqlegdad - Catalog DCS Database dcscat sqlenv
sqlegdel - Uncatalog DCS Database dcscat sqlenv
sqledcgd - Change Database Comment dbcmt sqlenv
sqledosd - Open Database Directory Scan dbcat sqlenv
sqledgne - Get Next Database Directory Entry dbcat sqlenv
sqledcls - Close Database Directory Scan dbcat sqlenv
sqlegdsc - Open DCS Directory Scan dcscat sqlenv
sqlegdgt - Get DCS Directory Entries dcscat sqlenv
sqlegdcl - Close DCS Directory Scan dcscat sqlenv
sqlegdge - Get DCS Directory Entry for Database dcscat sqlenv
Client/Server Directory Management
sqlectnd - Catalog Node nodecat sqlenv
sqleuncn - Uncatalog Node nodecat sqlenv
sqlenops - Open Node Directory Scan nodecat sqlenv
sqlengne - Get Next Node Directory Entry nodecat sqlenv
sqlencls - Close Node Directory Scan nodecat sqlenv
Network Support
sqleregs - Register regder sqlenv
sqledreg - Deregister regder sqlenv
db2LdapRegister n/a db2ApiDf
db2LdapUpdate n/a db2ApiDf
db2LdapDeregister n/a db2ApiDf
db2LdapCatalogNode n/a db2ApiDf
db2LdapUncatalogNode n/a db2ApiDf
db2LdapCatalogDatabase n/a db2ApiDf
db2LdapUncatalogDatabase n/a db2ApiDf
Database Configuration
sqlfxdb - Get Database Configuration dbconf sqlutil
sqlfddb - Get Database Configuration Defaults d_dbconf sqlutil
sqlfrdb - Reset Database Configuration dbconf sqlutil
sqlfudb - Update Database Configuration dbconf sqlutil
Recovery
sqlubkp - Backup Database backrest sqlutil
sqlurcon - Reconcile n/a sqlutil
sqlurestore - Restore Database backrest sqlutil
sqluroll - Rollforward Database backrest sqlutil
db2HistoryOpenScan - Open Recovery History File Scan n/a db2ApiDf
db2HistoryGetEntry - Get Next Recovery History File Entry n/a db2ApiDf
db2HistoryCloseScan - Close Recovery History File Scan n/a db2ApiDf
db2Prune - Prune Recovery History File n/a db2ApiDf
db2HistoryUpdate - Update Recovery History File n/a db2ApiDf
Operational Utilities
sqlefrce - Force Application dbstop sqlenv
sqlureot - Reorganize Table dbstat sqlutil
sqlustat - Runstats dbstat sqlutil
Database Monitoring
sqlmonsz - Estimate Size Required for sqlmonss() Output Buffer db2mon sqlmon
sqlmon - Get/Update Monitor Switches db2mon sqlmon
db2GetSnapshot - Get Snapshot n/a db2ApiDf
sqlmrset - Reset Monitor db2mon sqlmon
db2ConvMonStream n/a db2ApiDf
Data Utilities
sqluexpr - Export impexp sqlutil
sqluimpr - Import impexp sqlutil
sqluload - Load tload sqlutil
db2LoadQuery - Load Query loadqry db2ApiDf
General Application Programming
sqlaintp - Get Error Message util, checkerr sql
sqlogstt - Get SQLSTATE Message util, checkerr sql
sqleisig - Install Signal Handler dbcmt sqlenv
sqleintr - Interrupt n/a sqlenv
sqlgdref - Dereference Address n/a sqlutil
sqlgmcpy - Copy Memory n/a sqlutil
sqlefmem - Free Memory tspace sqlenv
sqlgaddr - Get Address n/a sqlutil
Application Preparation
sqlaprep - Precompile Program makeapi sql
sqlabndx - Bind makeapi sql
sqlarbnd - Rebind rebind sql
Remote Server Utilities
sqleatin - Attach dbinst sqlenv
sqleatcp - Attach and Change Password dbinst sqlenv
sqledtin - Detach dbinst sqlenv
Table Space Management
sqlbtcq - Tablespace Container Query tabscont sqlutil
sqlbotcq - Open Tablespace Container Query tabscont sqlutil
sqlbftcq - Fetch Tablespace Container Query tabscont sqlutil
sqlbctcq - Close Tablespace Container Query tabscont sqlutil
sqlbstsc - Set Tablespace Containers backrest sqlutil
sqlbmtsq - Tablespace Query tabspace sqlutil
sqlbstpq - Single Tablespace Query tabspace sqlutil
sqlbotsq - Open Tablespace Query tabspace sqlutil
sqlbftpq - Fetch Tablespace Query tabspace sqlutil
sqlbctsq - Close Tablespace Query tabspace sqlutil
sqlbgtss - Get Tablespace Statistics tabspace sqlutil
sqluvqdp - Quiesce Tablespaces for Table tload sqlutil
Node Management
sqleaddn - Add Node n/a sqlenv
sqledrpn - Drop Node Verify n/a sqlenv
Nodegroup Management
sqludrdt - Redistribute Nodegroup n/a sqlutil
Additional APIs
sqluadau - Get Authorizations dbauth sqlutil
sqlegins - Get Instance dbinst sqlenv
sqleqryc - Query Client client sqlenv
sqleqryi - Query Client Information cli_info sqlenv
sqlesetc - Set Client client sqlenv
sqleseti - Set Client Information cli_info sqlenv
sqlesact - Set Accounting String setact sqlenv
sqlurlog - Asynchronous Read Log asynrlog sqlutil
sqlugrpn - Get Row Partitioning Number n/a sqlutil
sqlugtpi - Get Table Partitioning Information n/a sqlutil
db2AdminMsgWrite n/a db2ApiDf
Note:

a
The sample programs can be found in the language specific directory of the samples directory in the sqllib directory (for example, sqllib\samples\c for C source code). The file extensions on sample code depend on the programming language being used. For example, for sample code written in C, the extension is .c or .sqc. Not all programs are available in all supported programming languages. Not all APIs have sample code (indicated by n/a).

b
The file extensions on INCLUDE files depend on the programming language being used. For example, an INCLUDE file written for C has a file extension of .h. The INCLUDE files can be found in directory sqllib\include (directory delimiters are dependant upon the operating system).


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]

[ DB2 List of Books | Search the DB2 Books ]