Hi,
I'm having trouble figuring out the right syntax. For instance, how can I create column that takes the difference between two existing columns? Only thing I've been able to figure out is using LEFT("X",1) to build a new variable.
Solved! Go to Solution.
`column1`-`column2`
?
Do you have to cast your columns as numbers first (ie are they strings?)
cast("column1" as int)-cast("column2" as int)
Is there a way to tell what the format is for In-DB? Or do you just have to know the underlying table? I don't think they are stings because I can summarize / sum them within the DB.
"Column1" - "Column2" doesn't work. I can see they are doubles in the summarize tool so that isn't the case. Could there be some permissions issue that doesn't allow me to do it but will allow me to do LEFT("Column3",1) without an error?
Hi @suppahc,
It shouldn't be a permission issue - the subtraction works for me. Are you giving the new column a name and outputting it as a Double? See the configuration below:
Can't have spaces.
I had:
"Col1" - "Col2"
When I took out the spaces it work.
Thanks so much!
Fantastic @suppahc! 😊