Hi Robin
First Thing : Thank you for looking into it and providing valid suggestions.
Made few changes :
1.I have removed distinct in the select query.
2.I already have indexes for both tables for required columns as below.
3.I observed my db2 uses MAX_LOG => 32 and LOGPRIMARY is 12(No way to extend this as its max provided by tool client ) and do get transaction log space error while loading first time since no data exists in target table.
Is there any way to split the logic based on row count and insert data in two parts . Like First 5 Million , then 5=M to Max count .
Or any other approach to load huge 8 Million data . Any help appreciated.
Hello all,
I just stuck up in an uncertain situation related to network performance...
I am trying to access one of my remote client unix machine from a distant location..
The client machine is Ultra-5_10 , with SunOS 5.5.1
The ndd result ( hme1 )shows that the machine is hooked to a... (5 Replies)
Hi
i m trying to connect DB2 via unix. it is successfully connect. but the connect is getting disconnect .
below is the query ,
countvalue=$(db2 "connect to <Database> user <username> using <Password>" | db2 -x 'select count(*) from <tablename>' ); echo $countvalue
while... (2 Replies)
Hi
I am extracting a column value(DESCRIPTION) from one table and passing it to another db2 statement in a shell code to fetch some value(ID) but the value when passed in where condition is taking as newline+value.
Please find the out put when executed:
+ echo description is ::::... (1 Reply)
hi friends,
i have a file where every word is present in a new line for example:
more file1:
i want to fetch previous line wherever i am getting "as" as a keyword.
i tried at home the follwing code in linex:
grep -B 1 "as" file1
ouput:
caste
caste1
it was working!!
but now i am... (6 Replies)
Hi all,
I am new for linux environment, and i am working as a DBA.
I am facing some issues in OS level:
In our dev boxes /db2home under this directory i'm not finding any folder but it's showing 98% used .
/dev/dm-14 5.0G 4.6G 115M 98% /db2home
# ls -lrt
total 16... (1 Reply)
hi
i am trying to execute db2 queries through shell script. it's working fine but for few queries is not working ( those queries are taking time so the script is not waiting to get the complete the execution of that query )
could you please any one help me on this
is there any wait... (1 Reply)
I have a shell script main.ksh We are calling dbscript.ksh from main.ksh
I am using select statement in dbscript.ksh but there is a problem with the select statement in dbscript.ksh but still echo $? is showing as zero. I am using DB2 commands in dbscript.ksh
Main.ksh
dbscript.ksh
echo $? ... (13 Replies)
Dear Team
Have this interesting question on how to determine cost savings(USD) based on performance tuning in Db2
I am using DB2 v10.5 . I worked on db2 procedure that loaded 20Million records in just 2 Mins.
ETL execution time reduced from 30 Mins to 2 Mins.
From 15 Hrs Monthly to 1... (2 Replies)
Hi Gurus,
I need to merge two files.
file1 (small file, only one line)
this is first linefile2 (large file)
abc
def
ghi
... I use below command to merge the file, since the file2 is really large file, the command read whole file2, the performance is not good.
cat file1 > file3... (7 Replies)
Discussion started by: green_k
7 Replies
LEARN ABOUT PHP
db2_client_info
DB2_CLIENT_INFO(3) 1 DB2_CLIENT_INFO(3)db2_client_info - Returns an object with properties that describe the DB2 database clientSYNOPSIS
object db2_client_info (resource $connection)
DESCRIPTION
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 con- | |
| | nection. | |
| | | |
| 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 imple- | |
| | ments 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 sup- | |
| | ported by the client: | |
| | | |
| | o MINIMUM | |
| | - Supports the mini- | |
| | mum ODBC SQL gram- | |
| | mar. | |
| | | |
| | o CORE | |
| | - Supports the core | |
| | ODBC SQL grammar. | |
| | | |
| | o 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". | |
| | | |
+---------------------+--------------------------------------+---+
PARAMETERS
o $connection
- Specifies an active DB2 client connection.
RETURN VALUES
Returns an object on a successful call. Returns FALSE on failure.
EXAMPLES
Example #1
A db2_client_info(3) example
To retrieve information about the client, you must pass a valid database connection resource to db2_client_info(3).
<?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);
?>
The above example will output:
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)SEE ALSO db2_server_info(3).
PHP Documentation Group DB2_CLIENT_INFO(3)