HanhDo
March 6, 2021, 10:37am
1
Hi everyone,
I would like to change data type of about 60 columns from integer to double at the same time.
I used Column rename which has the option of changing data type but I have to repeat similar procedure (select and change the type) for each of 60 columns.
I was wondering is there any node that allows to do this action for all columns at once?
Thank you very much for your help
Hanh
iperez
March 6, 2021, 1:39pm
2
Hi,
You can use the String Manipulation (Multicolumn) with the following formula toDouble(string($$CURRENTCOLUMN$$))
1 Like
The rename node is not a good option to change types unfortunately
OK I have a theory of what is going on with the rename node and the changed column types. It seems the rename node stores the information of which type it should assign to a column based on the originating type of the column in question. An integer would have other possibilities to be turned into than a Double.
[image]
[image]
The corresponding numbers are now stored in an XML file “settings.xml”
If I would now rename the integer into double and the Double into Fuzzy like this
[image]
T…
1 Like
ipazin
March 8, 2021, 10:34am
4
Hello @HanhDo ,
I would use Math Formula (Multi Column) node. And why changing column type to double? Check this topic for more:
Hi,
there are already several posts concerning Integer to Double, but from my point of view it is still not solved. How do I turn multiple integer columns automatically in to double columns?
There is a node double to int, but the other direction is still missing (int to double).
The Math formula (multi column) does the job [Integer to Double Using Math ], but strangely only for manual column selection. Why is the type selection missing? I have many int columns distributed amoung double columns…
Br,
Ivan
1 Like
HanhDo
March 8, 2021, 11:37am
5
Hi,
Thanks @iperez
Unfotunately, string manipulation node only works with rows in single column ;/
Br
Hanh
HanhDo
March 8, 2021, 11:42am
6
Hi @ipazin ,
yeah, this is exactly what I actually wanted to look for.
Thanks a lot for your help
Hanh
1 Like
iperez
March 8, 2021, 1:56pm
7
@HanhDo You are right, that’s why the suggested node is the Multicolumn String Manipulation one:
3 Likes
HanhDo
March 8, 2021, 4:49pm
8
ahhhh, ukie, now I got it. Thank a lots
Hanh
1 Like
system
Closed
March 15, 2021, 4:50pm
9
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.