BBjAdmin::getJdbcOdbcConnections

Description

In BBj 8.0 and higher, this method retrieves a BBjVector of BBjJdbcOdbcInfo objects; one for each JDBC or ODBC connection that is currently open. This does NOT include open SQL channels or RecordSet objects unless they are open from a remote interpreter.

Syntax

Return Value

Method

BBjVector

getJdbcOdbcConnections()

Parameters

None.

Return Value

Returns a BBjVector containing BBjJdbcOdbcInfo objects.

Remarks

The BBjVector will contain a set of BBjJdbcOdbcInfo objects. These BBjJdbcOdbcInfo objects contain the same information displayed in the Enterprise Manager when viewing the listing of all JDBC/ODBC connections on a server.

Example

rem 'Retrieve all active BBjJdbcOdbcConnection Objects

input "Enter User ID: ",userid$
input "Enter Password: ",password$
admin! = BBjAPI().getAdmin(userid$,password$)
vector! = admin!.getJdbcOdbcConnections()
print "Database",@(20),"OpenID",@(26),"Userid",@(36),"Host",
print @(56),"Connect Time"
for i = 0 to vector!.size()-1
    info! = vector!.get(i)
    print @(0),str(info!.getDatabase()),
    : @(20),str(info!.getID ()),
    : @(26),str(info!.getUser()),
    : @(36),str(info!.getHost()),
    : @(56),str(info!.getConnectTime())
next i
stop

See Also

BBjAPI

BBjAdmin

BBjAdminEnvironment

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.