Hot answers tagged

6

This simple question has caused an unusual amount of debate, and I feel compelled to quote an authoritative source. The database stores all data in tables that are related to one another. Relationships are established between tables such that data is shared and duplication is minimized. A table space is a storage structure containing tables, ...


2

FWIW, I tried investigating the differences between a newly created index in a db copy and the original index in syscat.indexes, sysibm.sysindexes and sysstat.indexes. The only difference I could spot was a slightly better density (100) for the new index compared with the old one (87). I therefore ended up recreating the index, and now the execution plan is ...


2

Based on your comment this seems to be an ISO week number, but the logic is the same for any other numbering schema: take the year and convert it to the first day of the first week of this year, then add the (weeknumber -1) * 7 to get the starting day of the week and add 4 to get Friday. I don't know about DB2 syntax, but a quick check revealed that TRUNC ...


1

I had the same problem. I set all foreign keys not enforced, then I loaded the tables and set the foreign keys enforced. Several fail. I do a query: SELECT TABSCHEMA, TABNAME, STATUS FROM SYSCAT.TABLES where status = 'C' For the tables, that are shown, I do a: set integrity for table immediate checked This works. Afterwards I can set all foreign keys ...


1

I believe this is a bug with the specific version of IBM's driver I was using. I was using the ODBC driver from IBM i Access Client Solutions Linux AP v07.03.00. I replaced that driver with the ODBC driver from IBM i Access for Linux v7.1.0-1.0 and now everything works as expected.



Only top voted, non community-wiki answers of a minimum length are eligible