0

I have created a SpatiaLite point layer in QGIS with each point having attribute NAME. I have since realised it would be useful to have a text field for NAME of notes/description. I have looked at this question Adding columns Lat,Lon but have no experience of where/how to enter the SQL expressions mentioned.

How do you populate the TEXT field once created?

0

1 Answer 1

0

SQL queries can be executed using the DB Manager, take a look at: Lesson: Using DB Manager to work with Spatial Databases in QGIS.

Populating the table can be done by editing and typing the values into the attribute table, using the Field Calculator, and by INSERT statements in the DB Manager see: Editing attribute values

8
  • I added the extra fields following the instructions but they did not show up when I clicked on "Open Attribute Table". When I tried to save it all the existing data was deleted.
    – Vic
    Jan 26 at 21:54
  • You might have to readd the layer to QGIS for new fields to show
    – BERA
    Jan 27 at 9:06
  • Bera, I'm familiar with a fair bit of QGIS but have never tried to edit a QGIS database. "read the layer to QGIS" conveys nothing to me. I added the extra fields easily after reading your link but as said they didn't show in QGIS and I lost all entered data. I have now started to recreate the layer but starting with a properly thought out database field set. Time is pressing but I will return to attempting editing when there is less presure.
    – Vic
    Jan 27 at 10:18
  • Did you have the GeoPackage layer open in the project while you were editing it with the DB Manager?
    – user30184
    Jan 27 at 14:32
  • Yes, open whilst editing in DB Manager.
    – Vic
    Jan 28 at 18:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.