New answers tagged fields-attributes
2
votes
Updating/Setting Field on GML file not working
The first line of the docs states:
OGR has limited support for GML reading and writing. Update of existing files is not supported.
And even if it was supported, you're opening the file in read mode ...
6
votes
Accepted
Deleting the same column(s) from different shapefiles in QGIS
A PyQGIS solution. Tested on QGIS 3.24.1-Tisler.
Proceed with Plugins > Python Console > Show Editor and paste one of the scripts below.
The press Run script and get the output.
This approach ...
1
vote
Unable to join data from another layer
If you want to join attribute data of one layer to other then you should use "Joins and Relates". Run the join command with "Join data from another layer based on spatial location"....
1
vote
Unable to join data from another layer
If you only need the attribute table from one layer to another, "join attributes by location" function with "intersect" geometric predicate, should work.
If each feature has it's ...
3
votes
Accepted
Renaming categorical attribute values in QGIS attribute table: merge two different strings to the same name
Just run Field calculator, update the field by typing this expression:
if (
"Species" in ('DD', 'Delphinus Delphinus'),
'Delphinus Delphinus',
"Species"
)
Here I ...
2
votes
QGIS misidentifying fields attribute type
Single quotes ' are for strings, double " for fields. So you are trying to sum the strings 'MTO heat map_total' and 'MTO heat map grouping'. Change ' to " so QGIS understand you are ...
0
votes
QGIS not always recognizing the field name from excel files
The trick is to add at least one numerical field as last column
5
votes
Filling attributes in one field based on second field with same values in QGIS
You can use a short PyQGIS script. First create your new field e.g. "ID_2" and fill it with the values from "ID_1" (the expression to do that is simply "ID_1").
Next open ...
1
vote
Maximum value of field of vector layer using PyQGIS
There are also several other approaches available:
Approach 1 : QgsAggregateCalculator with Max
Available aggregates to calculate.
Not all aggregates are available for all field types.
This approach ...
6
votes
Filling attributes in one field based on second field with same values in QGIS
If you want to update SID_1 with the value of SID_2 if SID_1 is NULL
choose Update existing field in the Field Calculator
execute a simple conditional:
IF( "SID_1" IS NULL, "SID_2"...
1
vote
Merging multiple point layers with common fields to create single table in QGIS
There is a possibility using a "Virtual Layer" through Layer > Add Layer > Add/Edit Virtual Layer....
Let's assume there are two point layers one called 'points1' and second called '...
0
votes
How to hide more than one QGIS attribute field at a time?
Couple of lines to set all field widgets to 'Hidden' for active (selected) layer, tested on QGIS 3.24 in Python Console:
layer = iface.activeLayer()
fields = layer.fields()
for i in range(0, fields....
1
vote
Merging multiple point layers with common fields to create single table in QGIS
Menu Processing > Toolbox > Merge Vector Layers.
Field calculator: create a new string (text) field with this expression: concatenate( to_string(unique_value1), concatenator:=',', group_by:=...
2
votes
Updating attribute field with values from list calculation using PyQGIS
Try this logic:
a = [134.24, 134.24, 134.24, 134.99]
b = [58.848430067837946, 70.46615125391358, 63.02756211443306, 60.662300968221174]
c = 0.6673779977746334
newlayer = iface.activeLayer()
with ...
2
votes
Adding name of each shapefile polygon to its attribute table with add field using ArcMap ModelBuilder
Your shapefile needs to be named differently. Since your model is failing on Add Field, I tested Add Field on a shapefile named test.tif.shp and it returned an error. I suggest trying to rename it ...
0
votes
Accepted
Trying to update attributefields from shapefile with field values from intersecting shapefile features
You can do it like this by using a spatial index for a greater performance. Check the code comments for explanations. As mentioned in the last comment, you did not mention what should happen if there ...
Top 50 recent answers are included
Related Tags
fields-attributes × 1568qgis × 610
arcgis-desktop × 305
arcpy × 227
attribute-table × 217
pyqgis × 140
field-calculator × 138
shapefile × 112
arcmap × 96
python × 76
attribute-joins × 61
qgis-3 × 58
layers × 55
arcgis-10.2 × 45
polygon × 42
point × 42
expression × 41
symbology × 38
arcgis-10.1 × 37
arcgis-10.0 × 33
arcgis-pro × 33
modelbuilder × 32
editing × 31
vector × 26
features × 26