[QGIS-Developer] Factorizing a dbf
Régis Haubourg
regis.haubourg at gmail.com
Mon Jan 22 05:02:15 PST 2018
Hi, maybe the field refactor alg' with a "replace()" mixed with a
attribute(get_feature , etc...) looking in the reclassification table could
do?
Cheers
Régis
2018-01-22 13:18 GMT+01:00 Luiz Motta <motta.luiz at gmail.com>:
> Hi Paolo,
>
> A possible insight can be this:
> - Create a table with two columns: 'string from SHP' and 'respective
> number code'.
> - In SHP create the Union with the table above.
> - Use Calculator for populate the new field in SHP with value of code.
>
> Good lucky.
>
>
> 2018-01-22 9:18 GMT-02:00 Paolo Cavallini <cavallini at faunalia.it>:
>
>> Hi all,
>> I have a large shp with a number of repeated strings, and I'd like to
>> refactor it replacing strings with a numeric code. I have found a
>> Processing alg that does it, creating a new file each time, which is
>> cumbersome; moreover, the alg apparently changes field type, adding
>> decimals to reals. Of course I could create a CASE statement, but this
>> is also cumbersome.
>> Is there a more straightforward way?
>> Thanks.
>> --
>> Paolo Cavallini - www.faunalia.eu
>> QGIS & PostGIS courses: http://www.faunalia.eu/training.html
>> https://www.google.com/trends/explore?date=all&geo=IT&q=qgis,arcgis
>> _______________________________________________
>> QGIS-Developer mailing list
>> QGIS-Developer at lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>
>
>
> _______________________________________________
> QGIS-Developer mailing list
> QGIS-Developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20180122/51021cee/attachment-0001.html>
More information about the QGIS-Developer
mailing list