Re: [Qgis-user] Problem Noticed with QGIS

2022-11-29 Thread Richard McDonnell via Qgis-user
Andrea,
Thank you for the clarification and the work around!
Regards,

Richard



——
Richard McDonnell MSc GIS, FME Certified Professional
FRM Data Management

——
Oifig na nOibreacha Poiblí
Office of Public Works

Sráid Jonathan Swift, Baile Átha Troim, Co na Mí, C15 NX36
Jonathan Swift Street, Trim, Co Meath, C15 NX36
——
M +353 87 688 5964 T +353 46 942 2409
https://gov.ie/opw

——
To send me files larger than 30MB, please use the link below 
https://filetransfer.opw.ie/filedrop/richard.mcdonn...@opw.ie

Email Disclaimer: 
https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/

——
MSc GIS, FME Certified Professional

——
Oifig na nOibreacha Poiblí
Office of Public Works

Sráid Jonathan Swift, Baile Átha Troim, Co na Mí, C15 NX36
Jonathan Swift Street, Trim, Co Meath, C15 NX36
——
M +353 87 688 5964 T +353 46 942 2409
https://https://gov.ie/opw<https://www.opw.ie>

——
Email Disclaimer: 
https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/<https://www.opw.ie/en/disclaimer/>
From: Qgis-user  On Behalf Of Andrea 
Giudiceandrea via Qgis-user
Sent: 29 November 2022 16:14
To: qgis-user@lists.osgeo.org
Subject: Re: [Qgis-user] Problem Noticed with QGIS

Richard McDonnell richard.mcdonnell at 
opw.ie<mailto:qgis-user%40lists.osgeo.org?Subject=Re%3A%20%5BQgis-user%5D%20Problem%20Noticed%20with%20QGIS=%3C9708d6dac99943929281a173e54a9e6f%40opw.ie%3E>
Tue Nov 29 07:17:48 PST 2022


1.   If I use the option [Create temporary Layer] it produces a Singlepart 
Geometry as Expected, If I save the output to a File, the resultant geometry is 
stated as Polygon (MultiPolygon) Its the same for Linestrings also.

Hi Richard,
as explained (also by me) in the linked issue report [1], the line (PolyLine) 
and polygon (Polygon) ESRI Shapefile layer types are actually multi-part layer 
types which can store both multi-part geometries with only one part and 
multi-part geometries with more than one part.
Only the point layer type has two different ESRI Shapefile layer types: the 
ESRI Shapefile Point type (which is a single-part type and can store only 
single-part geometries) and the ESRI Shapefile MultiPoint type (which is a 
multi-part type and can store multi-part geometries both with only one part and 
with more than one part).

Please see the ESRI Shapefile Technical Description [2].

If you want to check that a line (PolyLine) and polygon (Polygon) ESRI 
Shapefile layer imported in QGIS contains features with only 1 part, you need 
to check the number of part for each feature, for example using the 
num_geometries function [3] in the field calculator.

Best regards.

Andrea Giudiceandrea

[1] https://github.com/qgis/QGIS/issues/50720
[2] https://www.esri.com/Library/Whitepapers/Pdfs/Shapefile.pdf/
[3] 
https://docs.qgis.org/3.22/en/docs/user_manual/expressions/functions_list.html#num-geometries
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Problem Noticed with QGIS

2022-11-29 Thread Richard Duivenvoorde via Qgis-user

On 2022-11-29 16:17, Richard McDonnell via Qgis-user wrote:

We run the Check Geometries Tool and it flags the data as Geometry
Type Error. So I run the Multipart to Singlepart tool and….well
that's where the problem is…


Which 'Check Geometries Tool'?

What kind of data/file are you 'checking'? Shape file or Geopackage?


1.   If I use the option [Create temporary Layer] it produces a
Singlepart Geometry as Expected, If I save the output to a File, the
resultant geometry is stated as Polygon (MultiPolygon) Its the same
for Linestrings also.


If you say "save data to File": do you mean Geopackage?


Now I did find this.. https://github.com/qgis/QGIS/issues/50720 [1]
which flags the same issues, but states that its down to the Shapefile
Specification.


I read that issues as: there is (for QGIS or other tools), no way to 
write a singlepart line or polygon in a shapefile as the shapefile spec 
would not have a way to write that types in the shapefile.
So when you'll ask a shapefile 'what kind of geoms have you in your 
belly' it could actually not tell, unless it goes over all geoms and 
check what is in it...


Do you have examples of files which are OK?

What kind of tools do you use to check?

What does for example 'ogrinfo' report to you about your 'files'?

Regards,

Richard Duivenvoorde
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Problem Noticed with QGIS

2022-11-29 Thread Andrea Giudiceandrea via Qgis-user
*Richard McDonnell*richard.mcdonnell at opw.ie 


/Tue Nov 29 07:17:48 PST 2022/

1.   If I use the option [Create temporary Layer] it produces a Singlepart 
Geometry as Expected, If I save the output to a File, the resultant geometry is 
stated as Polygon (MultiPolygon) Its the same for Linestrings also.


Hi Richard,
as explained (also by me) in the linked issue report [1], the line 
(PolyLine) and polygon (Polygon) ESRI Shapefile layer types are actually 
multi-part layer types which can store both multi-part geometries with 
only one part and multi-part geometries with more than one part.
Only the point layer type has two different ESRI Shapefile layer types: 
the ESRI Shapefile Point type (which is a single-part type and can store 
only single-part geometries) and the ESRI Shapefile MultiPoint type 
(which is a multi-part type and can store multi-part geometries both 
with only one part and with more than one part).


Please see the ESRI Shapefile Technical Description [2].

If you want to check that a line (PolyLine) and polygon (Polygon) ESRI 
Shapefile layer imported in QGIS contains features with only 1 part, you 
need to check the number of part for each feature, for example using the 
num_geometries function [3] in the field calculator.


Best regards.

Andrea Giudiceandrea

[1] https://github.com/qgis/QGIS/issues/50720
[2] https://www.esri.com/Library/Whitepapers/Pdfs/Shapefile.pdf/
[3] 
https://docs.qgis.org/3.22/en/docs/user_manual/expressions/functions_list.html#num-geometries 
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Problem Noticed with QGIS

2022-11-29 Thread Richard McDonnell via Qgis-user
Hi All,
Im currently running the Following


QGIS version


3.28.1-Firenze


Qt version


5.15.3


Python version


3.9.5


GDAL/OGR version


3.6.0


PROJ version


9.1.0


EPSG Registry database version


v10.074 (2022-08-01)


GEOS version


3.11.1-CAPI-1.17.1


SQLite version


3.39.4


PDAL version


2.4.3


SpatiaLite version


5.0.1


QWT version


6.1.6


QScintilla2 version


2.13.1


OS version


Windows 10







I have the following issue.

As part of our Data verification Processes, we require that our data arrive as 
Singlepart Geometries.
We run the Check Geometries Tool and it flags the data as Geometry Type Error. 
So I run the Multipart to Singlepart tool andwell that's where the problem 
is...

Its two parts...


1.   If I use the option [Create temporary Layer] it produces a Singlepart 
Geometry as Expected, If I save the output to a File, the resultant geometry is 
stated as Polygon (MultiPolygon) Its the same for Linestrings also.



2.   When the New "corrected" layer is passed through the Check Geometries 
Tool, it flags it as a Geometry Type Error, even though I know its fixed, as I 
can validate it in an external tool.

Now I did find this.. https://github.com/qgis/QGIS/issues/50720 which flags the 
same issues, but states that its down to the Shapefile Specification.

Is there a work around for this??

Regards,

Richard



--
Richard McDonnell MSc GIS, FME Certified Professional
FRM Data Management

--
Oifig na nOibreacha Poibl?
Office of Public Works

Sr?id Jonathan Swift, Baile ?tha Troim, Co na M?, C15 NX36
Jonathan Swift Street, Trim, Co Meath, C15 NX36
--
M +353 87 688 5964 T +353 46 942 2409
https://gov.ie/opw

--
To send me files larger than 30MB, please use the link below 
https://filetransfer.opw.ie/filedrop/richard.mcdonn...@opw.ie

Email Disclaimer: 
https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/

--
MSc GIS, FME Certified Professional

--
Oifig na nOibreacha Poibl?
Office of Public Works

Sr?id Jonathan Swift, Baile ?tha Troim, Co na M?, C15 NX36
Jonathan Swift Street, Trim, Co Meath, C15 NX36
--
M +353 87 688 5964 T +353 46 942 2409
https://https://gov.ie/opw

--
Email Disclaimer: 
https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user