Setting a character or string as a numeric value

Setting a character or string as a numeric value

Adam84Adam84 Posts: 10Questions: 4Answers: 0

Hi, I have a table that uses a '~' character to represent no change in value. I'm using the 'Ignore text plugin' (link below). Is it possible to set this character to have a value of 0 so that it will sort between positive and negative values?

http://www.datatables.net/forums/discussion/22343/new-sorting-plugin-sort-by-any-number-ignore-text.

I have tried replacing the '~' character with a value of 0 but this doesn't seem to have worked. It would also be good if I could set a value to a string of my choice say for example 'No change'.

I've put a fiddle together as an example...

http://jsfiddle.net/Adam84/6LwnrLav/5/

Any help is much appreciated!

This discussion has been closed.