db2_client_info

(PECL ibm_db2 >= 1.1.1)

db2_client_infoReturns an object with properties that describe the DB2 database client

Beschreibung

db2_client_info(resource $connection): object

This function returns an object with read-only properties that return information about the DB2 database client. The following table lists the DB2 client properties:

DB2 client properties
Property name Return type Description
APPL_CODEPAGE int The application code page.
CONN_CODEPAGE int The code page for the current connection.
DATA_SOURCE_NAME string The data source name (DSN) used to create the current connection to the database.
DRIVER_NAME string The name of the library that implements the DB2 Call Level Interface (CLI) specification.
DRIVER_ODBC_VER string The version of ODBC that the DB2 client supports. This returns a string "MM.mm" where MM is the major version and mm is the minor version. The DB2 client always returns "03.51".
DRIVER_VER string The version of the client, in the form of a string "MM.mm.uuuu" where MM is the major version, mm is the minor version, and uuuu is the update. For example, "08.02.0001" represents major version 8, minor version 2, update 1.
ODBC_SQL_CONFORMANCE string

The level of ODBC SQL grammar supported by the client:

MINIMUM

Supports the minimum ODBC SQL grammar.

CORE

Supports the core ODBC SQL grammar.

EXTENDED

Supports extended ODBC SQL grammar.

ODBC_VER string The version of ODBC that the ODBC driver manager supports. This returns a string "MM.mm.rrrr" where MM is the major version, mm is the minor version, and rrrr is the release. The DB2 client always returns "03.01.0000".

Parameter-Liste

connection

Specifies an active DB2 client connection.

Rückgabewerte

Returns an object on a successful call. Returns false on failure.

Beispiele

Beispiel #1 A db2_client_info() example

To retrieve information about the client, you must pass a valid database connection resource to db2_client_info().

<?php
$conn 
db2_connect'SAMPLE''db2inst1''ibmdb2' );
$client db2_client_info$conn );

if (
$client) {
    echo 
"DRIVER_NAME: ";           var_dump$client->DRIVER_NAME );
    echo 
"DRIVER_VER: ";            var_dump$client->DRIVER_VER );
    echo 
"DATA_SOURCE_NAME: ";      var_dump$client->DATA_SOURCE_NAME );
    echo 
"DRIVER_ODBC_VER: ";       var_dump$client->DRIVER_ODBC_VER );
    echo 
"ODBC_VER: ";              var_dump$client->ODBC_VER );
    echo 
"ODBC_SQL_CONFORMANCE: ";  var_dump$client->ODBC_SQL_CONFORMANCE );
    echo 
"APPL_CODEPAGE: ";         var_dump$client->APPL_CODEPAGE );
    echo 
"CONN_CODEPAGE: ";         var_dump$client->CONN_CODEPAGE );
}
else {
    echo 
"Error retrieving client information.
     Perhaps your database connection was invalid."
;
}
db2_close($conn);

?>

Das oben gezeigte Beispiel erzeugt folgende Ausgabe:

DRIVER_NAME: string(8) "libdb2.a"
DRIVER_VER: string(10) "08.02.0001"
DATA_SOURCE_NAME: string(6) "SAMPLE"
DRIVER_ODBC_VER: string(5) "03.51"
ODBC_VER: string(10) "03.01.0000"
ODBC_SQL_CONFORMANCE: string(8) "EXTENDED"
APPL_CODEPAGE: int(819)
CONN_CODEPAGE: int(819)

Siehe auch

  • db2_server_info() - Returns an object with properties that describe the DB2 database server

Hier Kannst Du einen Kommentar verfassen


Bitte gib mindestens 10 Zeichen ein.
Wird geladen... Bitte warte.
* Pflichtangabe
Es sind noch keine Kommentare vorhanden.

Midjourney Tutorial - Anleitung für Anfänger

Über Midjourney, dem Tool zur Erstellung digitaler Bilder mithilfe von künstlicher Intelligenz, gibt es ein informatives Video mit dem Titel "Midjourney Tutorial auf Deutsch - Anleitung für Anfänger" ...

Mike94

Autor : Mike94
Kategorie: KI Tutorials

Grundlagen von Views in MySQL

Views in einer MySQL-Datenbank bieten die Möglichkeit, eine virtuelle Tabelle basierend auf dem Ergebnis einer SQL-Abfrage zu erstellen. ...

admin

Autor : admin
Kategorie: mySQL-Tutorials

Definition von Stored Procedures - eine Einführung

Stored Procedures sind vordefinierte SQL-Codeblöcke, die in einer Datenbank gespeichert sind und bei Bedarf aufgerufen werden können. ...

Bernie

Autor : ebiz-consult GmbH & Co. KG
Kategorie: mySQL-Tutorials

Tutorial veröffentlichen

Tutorial veröffentlichen

Teile Dein Wissen mit anderen Entwicklern weltweit

Du bist Profi in deinem Bereich und möchtest dein Wissen teilen, dann melde dich jetzt an und teile es mit unserer PHP-Community

mehr erfahren

Tutorial veröffentlichen

Berechnungen durchführen

Hallo liebe Forenmitglieder, meine erste frage ist zum Aufbau meiner kleinen Berechnungswebseite, nichts kommerzielles, soll nur eine Anwendung f ...

Geschrieben von matze511 am 21.04.2024 21:42:37
Forum: PHP Developer Forum
Professioneller Webentwickler & Webdesigner

Of course, here is the translation: Hello, Thank you for your interest in the long-term project. Your extensive skills and experience in web dev ...

Geschrieben von Athelstan am 15.04.2024 09:25:39
Forum: Jobgesuche
Wir stellen unsere SEO-Agentur vor

Hallo In der heutigen digitalen Welt war es für Unternehmen noch nie so einfach, ihre Reichweite weltweit zu vergrößern. Wenn Sie außerhalb I ...

Geschrieben von thomasmuller am 14.04.2024 07:18:33
Forum: User stellen sich vor
Spielplan für 4 Gruppen zu je 6 Teams auf 2 Feldern

Hallöchen zusammen, ich versuche derzeit unseren Excel-Spielplan in PHP zu überführen. Eigentlich bin ich auch shon fertig - wenn da nicht dies ...

Geschrieben von derH0st am 11.04.2024 15:58:37
Forum: PHP Developer Forum