Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
_AnonymousUser
Specialist III
Specialist III

how to catch and log "For input string:

Hi,
I am trying to catch and log all errors into a table for the file process, but did not get it.
I use the tLogCatcher together with tDie and tWarn, and checked all of "Dir on error" checkbox of related tables.
I loaded a positional text into related tables. When I run it, I got an "For input string" error as below ( I created it on purpose).
connecting to socket on port 3462
connected
For input string: "01843235.4"
disconnected
But tLogCatcher did not catch it. How should I do to make this work ?
Thanks !
Labels (2)
6 Replies
Anonymous
Not applicable

Hi
This error is thrown on the file input component, so you need to check the 'die on error' option on the file input component such as tFileInputPositional that you are using.
Note that the job will throw out the java exception and stop if the 'die on error' option is checked, and tLogCatcher will catch the error.
Shong
_AnonymousUser
Specialist III
Specialist III
Author

Yes, I could catch the error. But it is not what I expected.
What I expected is : just catch (actully log the error data) the error but let it continue to work like before(did not check the "die or error" check box.
Is there any to log the error data (for report and feedback purpose) instead of interrupt the process.
Thanks
Anonymous
Not applicable

Hi
If the 'die on error' option is unchecked, the job will not thrown out the java exception and tLogCatcher can't catch the error, however, the problematic record will be output to the reject flow if you link a reject flow out of the component, for example:
tFileInputPositional---main---tMysqlOutput
---reject---tFileoutputDelimited
Shong
_AnonymousUser
Specialist III
Specialist III
Author

Yes, this is what exactly I wanted. Thanks a lot for your answers.
By the way, how could I login in with regiested name to this forum. I registed with my name and setup the user name and password. When I log in, it always redirect me to my profile. After I come back, it still displays "You are not logged in."
Thanks !
James
alevy
Specialist
Specialist

It works with Firefox but not with Internet Explorer. If you want to use IE, you need to go to Exchange and log in there and that should also log you in to the forum.
_AnonymousUser
Specialist III
Specialist III
Author

OK, thanks !
My company only allows to use IE although I like the others such as Chrome and Firefox.
James