Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Loader doesn't import it's own exports, shows -5004 POS(228) Missing const

While trying to use loader to export and import I found an issue with one of our test instances. The export is done with

EXPORT DB CATALOG OUTSTREAM 'invocadb_ddl.catalog' DATA OUTSTREAM 'invocadb_pages.data'

now importing it into an empty instance I do

IMPORT DB CATALOG INSTREAM 'invocadb_ddl.catalog' DATA INSTREAM 'invocadb_pages.data'

and it shows this in it's log:

IMPORT DB CATALOG INSTREAM 'invocadb_ddl.catalog' DATA INSTREAM 'invocadb_pages.data'
// *
// M    Execute   PACKAGE  to transform  unlocked CATALOG 
// *
CREATE TABLE "IMAGES"
(
"IMAGEID"  Fixed (19,0)  NOT NULL  DEFAULT                    0,
"IMAGETYPE"  Integer  NOT NULL  DEFAULT           0,
"NAME"  Varchar (64) ASCII  NOT NULL  DEFAULT '0',
"IMAGE"  Blob  NOT NULL  DEFAULT  ,
CONSTRAINT SYSPRIMARYKEY PRIMARY KEY("IMAGEID")
)
// *
// E -25392:    '[SAP AG][LIBSDBOD SO][MaxDB] General error;-5004 POS(228) Missing constant'
// M    Loader    7.7.07   Build 016-121-231-153

What's wrong here? I understand it's the IMAGE Blob which shows a DEFAULT but no value. Is this a bug in the loader or did I miss something?

Thanks,

Simon

Former Member
Former Member replied

Hello,

1) What is the database version?

As you know the CLOB or BLOB is used to define an alphanumeric column of any length (not for temporary tables) as of for MaxDB versions 7.7. and higher.

If you have the MAXDB version 7.6 or lower could you use LONG BYTE < for BLOB type > and LONG ASCII (CLOB)

Please review the documents in MAXDB library at

http://maxdb.sap.com/doc/7_6/d1/2864403899970ae10000000a155106/content.htm

http://maxdb.sap.com/doc/7_7/45/3333809faf2b34e10000000a1553f7/content.htm

2) I could create tables in my database, version 7.7 with following statements:

CREATE TABLE "IMAGES"

(

"IMAGEID" Fixed (19,0) NOT NULL DEFAULT 0,

"IMAGETYPE" Integer NOT NULL DEFAULT 0,

"NAME" Varchar (64) ASCII NOT NULL DEFAULT '0',

"IMAGE" LONG BYTE NOT NULL DEFAULT '01',

CONSTRAINT SYSPRIMARYKEY PRIMARY KEY("IMAGEID")

)

Or

CREATE TABLE "IMAGES_1"

(

"IMAGEID" Fixed (19,0) NOT NULL DEFAULT 0,

"IMAGETYPE" Integer NOT NULL DEFAULT 0,

"NAME" Varchar (64) ASCII NOT NULL DEFAULT '0',

"IMAGE" BLOB NOT NULL DEFAULT '01',

CONSTRAINT SYSPRIMARYKEY PRIMARY KEY("IMAGEID")

)

3) Please let me know if you follow the document for Loader at

http://maxdb.sap.com/doc/7_7/e1/18a4ab1475462f8f4ab9f3bc4a7517/content.htm

< we have also u201CLoader Tutorialu201C in MAXDB library>

And document u201CExporting and Importing LOB Valuesu201D at

http://maxdb.sap.com/doc/7_7/32/7eb4b0c8eb4732babd8d32799dd22d/content.htm

So far I did not see that you used the u201Crule LOB OUTSTREAMu2026u201D and u201CLOB INSTREAMu201D.

Please let us know how the TABLE "IMAGES" was originally created & what is the database version to test loader export/import locally.

Thank you and best regards, Natalia Khlopina

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question