Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

Why no error message when execute SP failed?

Dear Experts,

I found a strange behavior when reloading my QV file.

I made a typo about a stored procedure name, so of course there no line fetched by that stored procedure (you can simply regard this scenario as: there's no such sp exists in the connected db).

But my point is, there is no error message popped out when reloading, neither anything logged down in the log file.

Is this a product bug or did I missed setting any options?

Thanks in advance.

Patrick

Tags (2)
14 Replies
giakoum
Honored Contributor II

Re: Why no error message when execute SP failed?

What error mode have you ?

ErrorMode

This variable determines what action is to be taken by QlikView when an error is encountered during script execution. By default (ErrorMode=1) the script execution will halt and the user will be prompted for action (non-batch mode). By setting ErrorMode =0 QlikView will simply ignore the failure and continue script execution at the next script statement. By setting ErrorMode =2 QlikView will trigger an "Execution of script failed..." error message immediately on failure, without prompting the user for action beforehand.

Example:

set ErrorMode=0;

Sokkorn
Honored Contributor

Re: Why no error message when execute SP failed?

Hi Patrick,

I'm afraid you set ErrorMode=0. Something like this

Set ErrorMode = 0;

Load ....

Regards,

Sokkorn

Not applicable

Re: Why no error message when execute SP failed?

Hi Ionannis,

Thanks for your reply.

It's 0, in log file it says so.

But I just tried manually change it to 1 and 2 in my script, the result is the same.

No error message prompted.

Seems QV doesn't regard sp that couldn't be found as an error.

Btw, I'm using QV 10g.

Patrick

giakoum
Honored Contributor II

Re: Why no error message when execute SP failed?

instead of sp, if you try to read from a table that does not exists, does it report an error?

Sokkorn
Honored Contributor

Re: Why no error message when execute SP failed?

Hi Patrick,

You may search all tab to find out ErrorMode=0

It may have more than one.

Regards,

Sokkorn

Not applicable

Re: Why no error message when execute SP failed?

Hi Sokorn,

Thanks for your reply.

There's no such setting in my script, it should be default set to 0, or perhaps there's some server level setting which I'm not sure of.

Do you mean I should manually set this to 1 instead of 0?

Patrick

Not applicable

Re: Why no error message when execute SP failed?

Yes, it does.

As well as wrong field name or something like that.

Sokkorn
Honored Contributor

Re: Why no error message when execute SP failed?

Hi Patrick,

By default, ErrorMode=1 (see in help file).

Now let try Set ErrorMode=1; on top of your script and see what happen when you load it.

Regards,

Sokkorn

Not applicable

Re: Why no error message when execute SP failed?

Hi Sokkorn,

Sorry for late reply.

I tried to set the error mode to be 0 ,1 and 2, all cannot solve it.

Seems QV doesn't concern if the SP exists.

One hint is that, In QV reload log file, no matter I type the right or wrong SP name, there's always one row to indicate it, and no error message:

......

2/12/2014 10:21:37 AM: 0074    SQL exec db.dbo.XXXXXX

......

Community Browser