dalibo/db2topg

index create

TomaszMru opened this issue · 2 comments

Hi i got an issue where try to use db2topg.pl
I got error
./db2topg.pl -f my_db2_sql_script.sql -o ../output -d pempik -u db2inst1 -p aefuc3Co
I don't understand COLLECT SAMPLED DETAILED STATISTICS in an CREATE INDEX section at ./db2topg.pl line 893, line 252.
It is part of creating index:

CREATE INDEX "DB2INST1"."IDX1701240806260" ON "schema"."table" ("ID_LOYAL" ASC, "ID" ASC, "LP_REGISTRATION_DT" ASC) COLLECT SAMPLED DETAILED STATISTICS COMPRESS YES INCLUDE NULL KEYS ALLOW REVERSE SCANS;

these script support db2 in 10.5 version?

Hi, that's just something that hasn't appeared in a dump I migrated yet. Please send the SQL script at cousinmarc at gmail dot com

I pushed a few changes.

There are some create table as select statements at the end that aren't understood anyway, and don't have any meaning in PostgreSQL. If you remove these, with what I committed, it should work.