Skip to Content
avatar image
Former Member

Unable to write to OS using EXPORT in Hana Express Edition VM

Hi,

My hdbsql EXPORTs fail systematically with error 12 below.

Tried /tmp, even a /hanatemp chmod'ed to 777 to avoid OS user/group restrictions - all to no avail :-(

IMPORT works like a charm if I create a .csv file in e.g. /tmp.

Export command used:

hdbsql=> export mytable as csv into '/tmp/qaz.txt' ;
* 12: cannot open file: Cannot open the path /tmp/qaz.txt SQLSTATE: HY000

This is a seriously blocking issue as I want to set up an easy EXPORT/IMPORT based mechanism to init and reset schemas.

I hope someone can shed some light on this...

Rgds,

PeterDH

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Jun 04, 2017 at 05:03 AM

    As the message says, the defined path cannot be open. The error message comes up, because you did define a file instead of just a path. The export command does not allow to define a specific file, because the generated files (not a single file, because the structure and content data is exported) are named automatically.

    Regards,
    Florian

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      OMG - that was really too easy ; yet there I was chmod'ing and stuff while the error stared me in the face :-(

      Thank you so much Florian for pointing this out - as an Oracle DBA doing my first steps in the Hana-world I thought I had spotted the similarity with Oracle's EXPDP/IMPDP commands but the simple fact that a PATH has to specified rather than a FILE had escaped my attention...

      Lesson learnt by self: RTFM - and if it doesn't work, RTFM again before bothering the experts ;-)

      Kind regards,

      Peter