The IBM DB2 Enterprise Server Edition is a relational model database server developed by IBM. It primarily runs on Unix (namely AIX), Linux, IBM i (formerly OS/400), z/OS and Windows servers.

learn more… | top users | synonyms

2
votes
2answers
321 views

DB2 db2fm proccess

Server is been up for 365 days, however i got some weird repeated procceses. Are these normal? ps -fea | grep db2fm db2inst1 643284 229516 29 May 25 - 212564:06 ...
1
vote
1answer
23 views

Change column from NOT LOGGED to LOGGED

I have a database DAT1 running on DB2 version 10.5. I want to enable logging for all CLOB and BLOB columns of my table TAB1. The table was initially created with those columns as NOT LOGGED but now I ...
1
vote
1answer
107 views

Error in loading data using DB2 load command in DB2 10.5

I have a IBM DB2 database in our application. We have a monthly Java batch process which loads data in the tables using "load Replace" sql command. Around millions of record will be updated every ...
-6
votes
0answers
30 views

Query is not running from the application side [closed]

A user is running a select query on the table TBLNAME on database DBNAME under instance - DB2INST1 (preprod). The select query keeps on running and not giving results. The same select query is ...
0
votes
1answer
1k views

DB2 Linked Server on SQL Server 2012 - Grant Access to Users

I have a linked server on SQL Server 2012 instance pointing to a DB2 database and I have Sys Admin access to that instance. I am unable to test connection to that DB2OLEDB database as I get below ...
3
votes
1answer
593 views

DB2 Materialised Query Table performance problems

I'm comparing performance on a series of tables involved in insert/updates/deletes. These tables are about to become the source tables for a Materialised Query Table so I thought getting some ...
0
votes
1answer
257 views

How to track IOPS statistics?

Is there a way to access statistics about IO operations per second in DB2 9.7? I am not interested in the buffer pool hit ratio, just IOPS.
4
votes
1answer
4k views

Split comma separated entries to rows

I have a Table like this: | ID | OtherID | Data +--------+-----------+--------------------------- | 5059 | 73831 | 5103,5107 | 5059 | 73941 | 5103,5104,5107 | 5059 | 73974 | ...
3
votes
1answer
644 views

How to avoid hardcoding a database link name in a package body

I have a PL/SQL package that copies data from a remote DB2 database using a database link. To keep the package configuration-independent I wrapped the remote table in a view. But a single field in a ...
2
votes
1answer
245 views

How to connect DB2 with eclipse on mac?

I tried to connect the DB2 Express-C Version 10.1 to Eclipse Mars but it returns an exception when I tried to run the program. com.ibm.db2.jcc.am.DisconnectNonTransientConnectionException: Error ...
0
votes
0answers
15 views

scheduler is not working with input parameter

Hello All I am beginner in db2, I wrote an admin task scheduler to run a stored procedure (which have no input parameter) every year 30th sept 1:10 AM using below command and its working fine when i ...
1
vote
1answer
32 views

DB2 SQL error: SQLCODE: -805, SQLSTATE: 51002

I am doing a batch process which fetches rows from table 50000 times. The query is: SELECT * FROM <table name> WHERE <condition; this changes for each iteration(50000)> This batch ...
1
vote
0answers
18 views

db2: configurations covered by “create db autoconfigure”

I am new to configuring memory in db2. I want to create a database using this command: db2 CREATE DB TEST USING CODESET UTF-8 TERRITORY US AUTOCONFIGURE USING mem_percent 80 APPLY DB ONLY According ...
1
vote
1answer
150 views

DB2 critical alert “database partition availability”

I have a existing DB2 database that I'm just getting started with and I have connected IBM Data Studio (web) to it and it says that it has the alert "Database Partition Availability" but it doesn't ...
2
votes
1answer
267 views

How to resolve foreign key references across different databases (iSeries and SQL Server)

I've got a system that has a DB2 iSeries database. We are rewriting a portion of the system and implementing it using SQL Server and Entity Framework. Originally, I was lead to believe that there ...
1
vote
1answer
3k views

Db2 Express doesn't start TCP/IP listener (SQL5043N)

At home, I've installed DB2 Express on my Win7 notebook, as a part of the IBM WebSphere installation. At first it was working, but then I restarted Windows and moved to the office, and since then I am ...
1
vote
1answer
106 views

DB2 importing/replacing fields from a file that contains XML

In two tables I have a column called table1.column_xml and table2.column_xml_2 defined as CLOB(1000000). The fields in the column contain XML formatted information like below column_xml ...
1
vote
2answers
83 views

How to get the Sum of all column values in the last row of a resultset without using UNION?

I need to get the sum of all column values of a result set in the last row. Here is my SQL query. SELECT CS_YEAR AS YEAR, CS_MNTH AS MONTH, CS_WK AS WEEK_NO, 'Total' AS ...
1
vote
1answer
62 views

Recovery model of current database

I want to know how can I change the recovery model of my current database. I am having sysadm rights.Operating system is windows, Db2 10.5. can some one let me know the command please
2
votes
1answer
363 views

How do you generate the DDL that created a db2 luw database?

There are various options for db2look you can use to see the DDL for just about every object in the database except the command that created the database itself. Is there any way with db2look, or ...
1
vote
2answers
169 views

The database manager failed to allocate shared memory because an operating system kernel memory limit has been reached

I have installed IBM DB2 10.5.5 and I want to create a new database there. When I entered command db2 create database test1 I am getting a error saying SQL1084C The database manager failed to ...
1
vote
1answer
3k views

How to Start DB2 10.5 HADR on the Standby Database

I am trying to set up HADR to run on my DB2 10.5 DB2 servers. I believe I have followed the steps correctly, but I'm getting the following error: [db2insh1@rslvm20 OneView]$ db2 restore database ...
1
vote
0answers
37 views

Error running DB2MOVE command

I'm trying to execute the DB2MOVE command at a db2 prompt console in a windows 7 machine (I have db2 client installed, with proper catalogs and nodes created and tested.). The steps I made was: ...
2
votes
2answers
34 views

DB2 add user with a password

I'm struggling here on how to do this I couldn't find anywhere or won't be able understand the documentation. So I'm connected as a DBA user on a DB2 client (TOAD for example) and I want to create a ...
0
votes
1answer
159 views

Apply DB2 logs from production to DR

Is it possible to Apply DB2 9.5 logs files from Production site to DR site? Or do I have to do Backup/Restore and rollforward ...? I copied log files from production site to DR and issued the ...
1
vote
0answers
30 views

See Full Exception String In Error Message

Right now I am trying to use HTTPGETCLOB function to pull data from an API. The problem is that the resulting error message does not show the whole exception string from the server. Below is the error ...
1
vote
1answer
43 views

What to do when the active log directory is full?

Here's my database configuration: Log file size (4KB) (LOGFILSIZ) = 125000 Number of primary log files (LOGPRIMARY) = 10 Number of secondary log files ...
1
vote
3answers
94 views

Difference between a schema and a database in db2

I can not figure out what is the difference between schema and database in db2 I find this SQL so confusing for example : CREATE TABLE schema1.table1 .... .... .... IN database1.tabspace1 Can ...
0
votes
1answer
194 views

DB2 big strange problem - database is returned to CIRCULAR mode but archive logs keep coming to old archive location

my DB2 database (v 9.7) is in Circular mode. Current Logging Type:Circular (USEREXIT) = OFF (LOGRETAIN) = OFF (LOGARCHMETH1) = OFF (LOGARCHMETH2) = OFF (LOGPRIMARY) = 10 (LOGSECOND) = 10 Path to log ...
3
votes
1answer
160 views

DB2 9.7, create or replace tablespace possible?

I am creating my tablespaces in the sql scripts that create the database schema. This causes a problem in continuous integration processes, where consecutive execution of the script is not possible ...
-1
votes
3answers
59 views

how to find the last date from the week number as input

I need to find the last date of week when i pass year and week number as input in my stored procedure. week starts on monday and last day of week will be friday. Database - IBM db2 9.7 platform - ...
1
vote
1answer
4k views

How to run DB2 export command in shell

I am trying to run the following DB2 command through the Python pyodbc module: DB2 export to C:\file.ixf of ixf select * from emp_hc I am successfully connected to the DSN using the pyodbc module in ...
1
vote
0answers
33 views

Automatic task scheduler is not working

I created a DB2 task to run my stored procedure automatically at a specific time, so below are the steps which I followed: First of all I enabled the task schedular using this command: db2set ...
1
vote
0answers
32 views

What does page size signify? [closed]

A page is a container of Data and it is the smallest I/O unit that a database deals with, but what does page size mean? For example what does a page size of 4KB tell us? Why not use page sizes of ...
0
votes
0answers
10 views

Is it possible to modify temporal history?

I have a case where we would like some data to "go away" forever. This could be, for example, to fix bad data created by a program bug, but the bottom line is that the business requirement would be ...
3
votes
1answer
9k views

How to run DB Admin Tool (GUI) in IBM DB2 Express-C?

I had installed IBM DB2 Express-C in Windows but I can't find any shortcut to launch the Administration Tools (GUI). When installing, I had selected "Administration Tool" option (I had checked twice ...
1
vote
1answer
32 views

IBM i Access ODBC driver returning only first letter of column names

I'm new to DB2 and am connecting to a DB2 for i (V7R1) database using unixODBC and the IBM i Access ODBC driver for Linux. When I query the database, the results only include the first letter of the ...
0
votes
0answers
25 views

Db2 JSON enablement

I followed the instructions to setup the JSON capability on my DB210.5 Windows server, running db2nosql... -setup enable. It succeeded, but when I launch the db2nosql I see this: nosql>Type your ...
3
votes
1answer
54 views

non-optimal use of index

I'm somewhat puzzled by the scenario below. The table involved (relevant parts) is defined as: CREATE TABLE Nya. UPSEC_COURSE ( UPSEC_COURSE_ID CHAR(11) NOT NULL, ...
1
vote
0answers
11 views

DB2 3-way Deadlatch

Encountered 3-Way DeadLatch, it happens when the tcb of the index file is reloaded, want to know what conditions would cause the tcb to be reloaded.
2
votes
1answer
34 views

How to see, if a foreign key is enforced?

How can I see in IBM DB2, if a foreign key is in enforced Status? In the systemviews REF_CONSTRAINTS and REFERENTIAL_CONSTRAINTS I see them, but I cannot see, if they are in enforced Status. Is there ...
3
votes
3answers
656 views

Reasons for db2 foreign key error (-667) despite all rows appearing sane?

I have some csv formatted table dumps and loaded those into a new database with the tables defined by a DDL script from the source database (both acquired by somebody else so I cannot have a look at ...
1
vote
0answers
10 views

DB2 Iseries - dml change logs

Iseries system using I/90 Is there a way to check changes made to database object like tables and views from any systables or system views or any logs on db2 for iSeries machine.
0
votes
1answer
30 views

DB2 simple order by query

I am very new to DB2.have installed Express C version and facing some problem while running a simple query. SELECT A,B,C,D,E,F,G, H FROM TABLE_NAME where A=9999 ORDER BY D Note: A through H ...
0
votes
0answers
20 views

Remote connection failing to run any command

Our partner has created a new database to us so we can use it as a test database. He gave us all addresses and connection information so we can use it to connect to the database. I've asked here how ...
1
vote
1answer
21 views

Problem when extracting the structure of DB2 (Back up Structure)

I want to extract the structure of a 9.7 DB2 database to use to clone it but some of the authorization statements are missing afterwards: I tried something like this: db2look -d dbName -a -x -o ...
1
vote
1answer
30 views

Add a DB2 catalog to a new remote server and make it work

I'm trying to add a new database catalog to my client environment in a windows server machine. So I've run the db2cmd tool and then the db2 tool on a windows command console once there I executed the ...
0
votes
0answers
25 views

How can I partition a table in DB2 luw

I want to know if there is an option that substitute "PARTITION BY SIZE" in DB2 luw , it works in DB2 zOS, but it is not supported by luw
0
votes
1answer
39 views

Dump specific tables from DB2 database

Is there any command line tool that I can use on a DB2 database to dump a specific set of tables? The problem is that I work in an application that its database tables was created in an existing ...
1
vote
1answer
97 views

DB2 LUW Timestamp differences in versions

Im new to DB2, my back ground is in MS SQL server 2000 thru 2012. I have a developer using Local DB DB2 LUW v9.7.500.4299 FIXPACK_NUM = 5 She is selecting some data from a table where the field ...