I've got a text attribute which contains intervals like "2 - 4". I would like to convert it to an attribute of type Real containing the start value of the interval.
This formula used to store the result in a "normal" attribute of type Real works as expected: toreal( (substr("interval" ,1,strpos ("interval" ,'-')-1))) The same formula used to store the result in a virtual attribute of type Real *results in NULL values*. Looking at the Fields tab of the layer properties shows one difference*: Both the "normal" and the virtual attribute has "Type" double while the "normal" attribute has "Type name" Real and the virtual attribute has "Type name" double. Don't know if that means anything? Both attributes has length 8 and precision 2. ----- Regards Morten Currently using Qgis 2.4.0 (OSGeo4), Windows 7, 64bit -- View this message in context: http://osgeo-org.1560.x6.nabble.com/Problem-with-virtual-field-in-field-calculator-tp5174697.html Sent from the Quantum GIS - User mailing list archive at Nabble.com. _______________________________________________ Qgis-user mailing list Qgis-user@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-user