Page 1 of 1

TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 7:03 am
by himanshurai420
Hi all,

I am new to TM1 and trying to create a TM1 process to write data into .csv file from a cube view and for the same i m using asciioutput function.
Below is the function and the error message.

Code: Select all

asciioutput('file.csv
',version
,category
,detail
,unit
,component
,numlist
,period
,numbertostring(value));
Error message:-
Data source line (1) error: data procedure line(0):cannot convert field number 8,value held for approval to a real number.
the above mentioned error is coming for all the records,

Could anyone of u please help me out.

thanks in advance.... :)

Re: TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 7:48 am
by Wim Gielis
Hello

Did you check the variable type (numeric or string) for your 8th variable?

Please also note that AsciiOutput requires every argument to be a String (text instead of numeric).

Wim

Re: TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 8:37 am
by himanshurai420
Thanks Wim,

The variable type is string for field number 8.

thanks one again for ur information about Asciioutput function.

:)

Re: TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 8:44 am
by Wim Gielis
Please provide screenshots of the variable Preview, the variables tab, the code and the error message.

Re: TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 8:52 am
by himanshurai420
Sorry wim,

not able to provide the screenshot and the variable type is number of the field 8.

thanks...

Re: TM1 process error :Cannot convert field 8

Posted: Mon Jul 13, 2015 5:45 pm
by Wim Gielis
Then set the variable type to String and if needed, use functions like StringToNumber, StringToNumberEx or Numbr to convert text to a number.
See: http://users.skynet.be/fa436118/wim/tm1 ... ngs_EN.htm

Re: TM1 process error :Cannot convert field 8

Posted: Tue Jul 14, 2015 5:55 am
by himanshurai420
Thanks a lot Wim.....It worked :)

Re: TM1 process error :Cannot convert field 8

Posted: Tue Jul 14, 2015 7:36 am
by Wim Gielis
You're welcome !