Please be aware that the content in SAP SQL Anywhere Forum will be migrated to the SAP Community in June and this forum will be retired.


I have a problem with the dbunload and the unprocessed.sql file.

I use SQL Anywhere Version on macOS.

With this version when I try to do an unload througth my App executing the sfollowing shell command :

/Applications/8sens\ sybase/SetupSyb/System/bin64/dbunload -ar -bp -l -c "UID=DBA;PWD=****;DBF=/Applications/8sens sybase/Databases/Demov8.db"

SQLA try and fail to create the unprocessed.sql file in my Home directory. According to the documentation it shouldn't try to create this file, because unprocessed.sql is created only if the option -ae is specified and it is not the case here.

Is there a way to block the creation of unprocessed.sql or to specifiy where it should be created ?

Thanks in advance.

asked 01 Jul '21, 11:11

Ben8sens's gravatar image

accept rate: 44%

edited 01 Jul '21, 11:13

I don't use MacOS, so that's just a wild guess:

See this note from the v17 read me, a bug fixed slightly after your build:

    ================(Build #4020  - Engineering Case #810172)================

    When dbunload version 17 is run, it creates an unprocessed.sql file in the 
    current working directory. If that directory is not writable, then dbunload 
    will fail.

    This problem has been fixed. 

    A new option -ru is provided to specify the location and name of the unprocessed 
    SQL statements file. It is similar to the -r option which is used to specify 
    the location and name of the “reload.sql” file.

    -ru <file>     path of unprocessed SQL file (default "unprocessed.sql")

    Also, if the unprocessed SQL statements file cannot be written to the current 
    working directory or the directory specified by -ru, then it is written to 
    the temporary files folder specified by either the dbunload -dt option or 
    by one of the SATMP, TMP, TMPDIR, and TEMP environment variables.
(01 Jul '21, 12:37) Volker Barth

Thanks I will try this options.

(01 Jul '21, 12:42) Ben8sens
Replies hidden

According to the documentation it shouldn't try to create this file, because unprocessed.sql is created only if the option -ae is specified and it is not the case here.

IMHO, that's a misunderstanding: That file is always created when a unload via internal rebuild using -ar or -an fails. The -ae flag just tells the dbunload process to skip the failing statement(s) and to continue, whereas without -ae the process would stop.

(01 Jul '21, 12:46) Volker Barth

Hm, as they were introduced with, I'm not expecting them to work with your build...

(01 Jul '21, 13:29) Volker Barth

I tried all the option, -ru doesn't work because it is not in my version of SQLA.

I tried the -r and -dt options but it doesn't work neither.

I tried to create the unprocessed.sql by my self and put full rigth on it. With the real shell it using it but not with my app :(.

I can't change the version of SQLA rigth know.

If anybody has an idea ...

(02 Jul '21, 06:46) Ben8sens
Replies hidden

Have you made sure that the dbunload process is allowed to write in the current working dir?

As stated, I don't use Mac OS, so just another wild guess: May this be due to "sourcing" the according shell script?

(02 Jul '21, 08:15) Volker Barth
showing 4 of 6 show all flat view
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 01 Jul '21, 11:11

question was seen: 671 times

last updated: 02 Jul '21, 08:16