Jump to content
We've recently updated our Privacy Statement, available here. ×

Why doesn't a scripted data type transformation work if the data type was already changed using the Expanded Data Panel

Tim McCune 3

Recommended Posts

I'm writing a script that manages data types but I've noticed that the script can't change the type of a column if that column's type has already been changed using the data type dropdown in the Expanded Data Panel.

But if the column's type has been changed by using Insert - Transformations - Change data types from the GUI, then the script can still change the data type.

If I go to the Expanded Data Panel, then "Go to table view" and "Source view", it appears that changing the data type using the Expanded Data Panel results in a fundamentally different transformation than you get from using "Insert" - "Transformations" - "Change data types".

Is it possible to alter the column type from a script after it's been changed with the Expanded Data Panel

Here's an example script:

from Spotfire.Dxp.Data import *

from Spotfire.Dxp.Data.Transformations import *


arrayColumnSig = []

columnSig = DataColumnSignature("Column1", DataType.Integer)


t=ChangeDataTypeTransformation(arrayColumnSig, DataType.Real)


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...