Questions tagged [attribute-joins]

The process of connecting two or more datasets based on common attribute values. For spatial joins there is a separate tag.

Filter by
Sorted by
Tagged with
31
votes
6answers
39k views

Joining multiple records to single feature using QGIS

I'm trying to create a join/relate in QGIS where I have a shapefile of buildings and to that I would like to join a non-spatial table (.csv-file) containing people who work in each building. So I have ...
37
votes
5answers
26k views

Joining attributes from nearest point in QGIS?

I have two layers with points, call them A and B, each with different attributes. For each point in A I want to join all the attributes from the nearest point in B. Ideally this would also include ...
46
votes
4answers
50k views

Joining non-spatial CSV file to spatial data (shapefile) using QGIS

I have a CSV file which has postcode data in a field, but it is non-spatial e.g. no Easting and Northing. I have a shapefile with postcode in a field and some additional data. I want to join the ...
18
votes
7answers
65k views

Joining data from Excel to attribute table in QGIS without creating duplicates?

I have an attribute table with two empty fields in QGIS. I want to import an excel database to fill my empty fields in QGIS. My excel file matches the columns in my QGIS attribute table. I am able ...
5
votes
3answers
5k views

Joining table field with shapefile using PyQGIS

The following is currently unsuccessful at fulfilling a table field join to a point shapefile in QGIS. All instances of the join object will print the proper values, and no error is flagged when ...
33
votes
2answers
52k views

Joining polygons in R

I am wondering how to join spatial polygons using R code? I'm working with census data where certain areas change over time and I wish to join the polygons and the corresponding data and simply ...
10
votes
2answers
8k views

One-to-many joins in QGIS [duplicate]

I am looking for a possibility to make a one-to-many table-join in QGIS. I have a shapefile with postal codes and would like to join them with survey results (more than one). In other words, there is ...
9
votes
7answers
62k views

Joining Excel table to shapefile in ArcMap?

I have a shapefile of lower layer super output areas (LSOA) for England and Wales and I have a spreadsheet of the indices of deprivation for each of the LSOA's in England. I want to join the ...
21
votes
3answers
11k views

How to symbolize features with NULL values in graduated symbology?

I have a polygon feature dataset, and an attribute from a different table that I join (one-to-one) within QGIS in order to symbolise the attributes as a choropleth map. However, not all polygon fields ...
10
votes
2answers
3k views

Difference between two layers in PostGIS

What is the right way to calculate the difference between two layers? I tried to use the following approach: SELECT ST_Difference(river.geom, lakes.geom) FROM river LEFT JOIN lakes ON ST_Intersects(...
14
votes
3answers
6k views

Join CSV file to shapefile using gdal/ogr

I have a shapefile with several attributes, for example "YEAR", "COUNTY", and "AREA". I also have a CSV file with more fields that I want in the shapefile, such as "...
13
votes
4answers
14k views

Join attributes of point and line layer by location (closest distance) in QGIS

My problem is the following: i have a line shp (target layer) and a point shp (join layer). the second one (point layer) holds an attribute which i want to join with a line layer based on closest ...
3
votes
4answers
1k views

How to assign geometry to records in a table that contain an ID of a geometry point?

We are looking to map out 'incidents' at schools, but the incident table, which contains a few thousand records, only has a school number (plus the incident data). The table format is an Excel ...
3
votes
3answers
4k views

Count points within each buffer QGIS

What I am trying to accomplish is to find the number of points that intersect a created buffer. I.E. I have a layer called "Buildings", for each building I have fixed distance buffers (<400m). I ...
11
votes
2answers
22k views

Join / merge lines that touch and intersect in QGIS

I have a large dataset consisting of lines/polylines where I would like to join/merge the lines that touch / intersect. Each line has an individual ID and there are no common attributes I can use for ...
10
votes
3answers
4k views

Detecting Join programmatically using ArcPy?

I have some Python code that is launched from within an ArcMap project. Any joins that the user may have created in the project must be removed in order for my code to run. Unfortunately, the code ...
7
votes
2answers
5k views

Keep the same field headers after joining a table to a shapefile in QGIS

I noticed that after joining a table to a shapefile the headers of each fields in the table used for the join are changed by QGIS and they are attributed to a different name. For instance, I had a ...
6
votes
1answer
9k views

After performing table join all the fields are "NULL" in QGIS

Within QGIS, I joined .dbf table containing population data to a shapefile of Census tracts. The join field is called "GISJOIN" in both the target table and the shapefile's table, and this ...
4
votes
1answer
8k views

How to Calculate Field in joined table using ArcPy?

I have to calculate a field based on another field in a joined table, but an error occurs: "Parameters are not valid. ERROR 000728: Field !Table_A.field_A! does not exist within table" My code: ...
5
votes
1answer
3k views

Joining table to shapefile using PyQGIS [closed]

Joining shapefiles is a relatively straightforward proess in QGIS using 'add vector join' in the layer properties menu. I can add a csv file as a vector layer, as well as a shapefile, and join the two ...
13
votes
1answer
4k views

How to perform a spatial join of point and polygon layers in PostGIS?

I have a point dataset representing households that I want to associate with a parcel layer (i.e. assign its parcel_id). With ArcMap, I could spatially join the polygons to the points and specify that ...
4
votes
1answer
4k views

Using many-to-many join in ArcMap

I'm working in ArcMap 10 and can move around in R, though am not an expert. I have a shp file and an xlsx file. The shp file is 20,221 rows and includes a field GID (grid ID) which is not unique ...
3
votes
1answer
6k views

Is exporting to feature class the simplest way to make joins permanent?

I am a new user doing simple tasks with ArcMap 10.1 I have a shapefile and an excel file, and I want the join to be a permanent part of the shapefile. The way I've been going about this is to export ...
2
votes
4answers
12k views

can't join excel(2013) to ARCGIS 10.2.2

When trying to join Excel datafile to shapefile in ARC GIS 10.2.2 I keep getting the following message: "Failed to connect to database. An underlying database error occurred. Class not registerd." ...
12
votes
2answers
18k views

One-to-many joins on a feature class to a table

I am using ArcMap 10.2.2 with an Advanced license. I have used ArcMap for other basic analyses, but am fairly new to the program and have only basic coding skills, with no SQL experience outside of ...
9
votes
5answers
2k views

Programatically identifying Joined Field in ArcMap?

Is it possible to programmatically identify the Join Field that is being used to Table Join two datasets together in ArcMap? I am currently using ArcGIS 10.0, SP5 and would prefer an ArcPy solution, ...
6
votes
6answers
2k views

How do I remove a join (between a standalone table and a feature layer) with ArcObjects?

I already know how to do a table join with ArcObjects, via the IDisplayTable, IMemoryRelationshipClassFactory etc. interfaces. Here are some links to resources that have example code for this: "...
11
votes
3answers
13k views

Joining tables without losing original field names in ArcGIS for Desktop?

I'm wondering if there is any method to preserve the original field names in ArcGIS when I join csv. tables to a Shapefile. I ask, because sometimes I join tables with 10, 20 or even more columns ...
7
votes
4answers
9k views

How to close multipart polyline gaps in ArcMap

I have a multiple multipart contour lines that originally came from CAD drawing. I converted these into a polyline shapefile in ArcGIS. The issue I have is with gap in each contour lines that are ...
4
votes
2answers
2k views

Joining attributes from points to lines QGIS

I am working with two shapefile layers: lines and points. These shapefiles do not overlap and have different attribute values. The point layer contains data that I want to join to the beginning and ...
3
votes
1answer
1k views

Joining layers with PyQGIS 3

I am trying to join layers programmatically following the answers in the Joining table field with shapefile using PyQGIS # Get input (csv) and target (Shapefile) layers shp = iface.activeLayer() csv = ...
2
votes
2answers
8k views

Joining Fields from Multiple Tables to One Table in ModelBuilder?

I have 40 tables with about 2000 row with a shared ID that I want to merge into 1 table with 2000 rows. I only want to retain a distance field calculated within each table. The distance field is ...
4
votes
3answers
2k views

How to join a WFS layer to a stand-alone table in OpenLayers

I'm a complete novice at OpenLayers, and am checking whether the following is possible. I envisage a dataset of polygons in GeoServer, being served as a WFS layer into OpenLayers. The polygons won't ...
3
votes
1answer
3k views

Joining attributes by field value not working

I cannot figure out why this join is failing when using the Join attribute be field value tool in QGIS 3.6. Please see my image below which highlights the two layers attribute table and the criteria ...
3
votes
1answer
899 views

PostgreSQL PostGIS: Spatial join but keep all features that don't intersect

Spatial joining a point table to a polygon table, creating a new output table. So far I can only get the output table to contain features that satisfy the spatial join. However, I want the output to ...
3
votes
1answer
10k views

Using Join in model gives ERROR 000840?

I'm trying to build a model using Model Builder in ArcGIS 10.1 that starts off by joining two shapefiles together based on a common field. I would like to make this open ended (not hardcoded) so I can ...
1
vote
1answer
3k views

Join Attributes by Location - Precision

What does "Precision" do within "Join Attributes by Location"? Also, what's the difference between the "Geometric Predicates"?
0
votes
1answer
443 views

Using AddJoin_management gives ERROR 000840? [duplicate]

While i'am trying to execute this code IN IDLE, i got error : import arcpy import math import arcview from arcpy import env arcpy.env.workspace = "D:/Users/saadiya/Documents/ArcGIS/Default.gdb" ...
11
votes
1answer
16k views

Creating spatial "Many to one" join

I'm trying to create what I call a "many to one" join. I don't know if that would be the correct term or not. I have a table that has unique account numbers for mobile homes (i.e. - M1007970) per ...
7
votes
1answer
3k views

Most efficient method to join multiple fields in ArcGIS

I have as set of shapefiles with approximately 300000 polygons each, as well as corresponding point shapefiles and tables with approximately the same number of row (equal or less rows than the ...
5
votes
1answer
1k views

Nearest facility with pgRouting

I have a PostgreSQL table of students with lat, lon and geom, and a table of schools with the same, and a table of roads that has been converted to nodes. I'm trying to find the driving distance to ...
13
votes
2answers
17k views

How to join external tables with a shapefile's attribute table in QGIS?

I need to join a .csv table into an attribute table of a shapefile. I wanted to do this with QGIS and i don't seem to find anyway of doing it. I know that the mmqgis plugin does it, but my shapefile ...
6
votes
2answers
185 views

How to group polygons based on spatial proximity and field value?

I have a shapefile consisting of the day of the year on which the temperature in a lake exceeds 15 degrees Celsius. I can see clear patterns in this (here seen as a raster): I want to group the ...
8
votes
2answers
6k views

How to join a table to a shapefile with non-matching IDs and names (similar strings)?

I'm having an annoying problem that I'm trying to find an automated solution for. The shorthand version is that I have a shapefile and a table of created data for regions within countries. The created ...
6
votes
1answer
3k views

How do "join field" and "target field" work?

New user. This should be simple, but I can't figure out how to perform this basic join in QGIS. (It works in Cartographica.) My shapefile (IL_BNDY_County_Py) has two fields/columns in its attribute ...
4
votes
1answer
452 views

Merging touching lines in QGIS

I have a vector layer, in which structures (pipes under roads) are made up of multiple lines. I wish to spatially join all the lines that make up a single structure, but cannot figure out a way to do ...
4
votes
2answers
2k views

Using Spatial join for many to one relates in ArcGIS for Desktop?

I'm trying to do a spatial join that takes the attributes of multiple polygons and applies them to a single polygon in another layer. The data is currently in a geodatabase, but can be exported to shp ...
4
votes
0answers
373 views

PyQGIS joining a dbf to a shapefile [duplicate]

I am trying to join a shp and dbf file using the PyQGIS API. The code I'll use is below: from PyQt4.QtCore import * vector1 = QgsVectorLayer("path to dbf file", "test1", "ogr") id1 = vector1.id() ...
8
votes
2answers
15k views

Creating join based on multiple fields using ArcGIS Desktop?

I have two feature classes in a File Geodatabase that I would like to join based on multiple fields. I've searched this site and Google and all I have come up with was to use the Make Query Table ...
5
votes
1answer
935 views

Performing specific table joins in QGIS via python?

I am trying to update an existing field on a shapefile using data from another shapefile. Basically, each attribute table contains an ID field that I want to use to update a field called "address". ...