1

I'm trying to add a layer to my QGIS project from this URL: http://quegis.labcd.unipi.it/cgi-bin/qgis_mapserv.fcgi?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetCapabilities

Using a WMS connection, I'm able to open it in jpeg or PNG format, but I don't know how to retrieve the alphanumeric part, i.e. feature attributes, which is the interesting part for me. Am I making a mistake or is it impossible via WMS?

Houska
8,71124 silver badges53 bronze badges
asked Dec 5, 2019 at 17:11
6
  • 1
    which alphanumeric part? it is just a map of buildings when I view it Commented Dec 5, 2019 at 17:16
  • So it's not my problem. I can't see anything else because there is nothing else, right? Commented Dec 5, 2019 at 17:38
  • What makes you think there should be an alphanumeric part? Are you expecting an attribute table? A WFS (web feature service) layer could have an attribute table, but a WMS (web map service) layer doesn't have attributes because it's just a raster image. Commented Dec 5, 2019 at 17:48
  • I need an attribute table, but I'm not sure that there is one. Is there a way to verify if the alphanumeric part exists? Commented Dec 5, 2019 at 17:53
  • 1
    WMS only provides image tiles. There is no 'alphanumeric part' or attribute table. It does not exist when working with a WMS. You need a WFS Commented Dec 5, 2019 at 18:05

1 Answer 1

2

You can get attribute information from a WMS by using a GetFeatureInfo request. A GetFeatureInfo request is a request for information at a point location (a pixel location in the map image).

GetFeatureInfo is an optional operation of a WMS, you can tell whether a layer supports such a query by looking at the GetCapabilities response, in your example it is (queryable="1"):

<Layer queryable="1">
 <Name>benigeo</Name>
 <Title>benigeo</Title>

In QGIS the GetFeatureInfo request is performed using the 'Identify Features` tool.

In this case there is also an associated WFS:

http://quegis.labcd.unipi.it/cgi-bin/qgis_mapserv.fcgi?SERVICE=WFS&REQUEST=GetCapabilities

And you could fetch data using a GetFeature request

answered Dec 21, 2019 at 18:40
2
  • By the way, it's actually pretty frequent that a published WMS service is shadowed by a WFS which may or may not be publicized. Ditto ArcGisMapServer -> ArcGisFeatureServer. It's always worth just making the obvious URL changes and seeing if it can be coaxed into working. Not always, of course. Commented Jan 28, 2020 at 18:43
  • +/- or a WCS, depending on the input data Commented Jan 28, 2020 at 18:48

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.