qgis – Fix .prj File Recognition Issue for NAD_1983_Canada_Atlas_Lambert

coordinate systemgdalqgis

I'm a fairly new user of QGIS and I've run into an issue that I can't seem to solve on my own. I'm trying to work with the NRCan Atlas of Canada Waterbodies SHP file but I'm having an issues re-projecting other datasets to line up with this one.

When I reviewed the .PRJ file packaged with the NRCan data, it indicates it is Lambert Conformal Conic projection with two standard parallels at 49°N and 77°N (see .PRJ text below); however, when I add the file to QGIS (v1.8.0-Lisboa) and view the layer properties, the CRS is displayed as follows:

USER:100001 – * Generated CRS (+proj=lcc +lat_1=49 +lat_0=49 +lon_0=-95 +k_0=1 +x_0=0 +y_0=0 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs)

Note that the second standard parallel (which should be in there as '+lat_2=77') is missing… I'm hoping this explains why my other datasets aren't lining up when I project them, but I can't seem to get QGIS to recognize the second parallel.

Suggestions? Or is this second parallel not an issue for re-projecting data?


Unmodified NRCan .PRJ file contents

 PROJCS["NAD_1983_Canada_Atlas_Lambert",
 GEOGCS["GCS_North_American_1983",
  DATUM["D_North_American_1983",
  SPHEROID["GRS_1980",6378137.0,298.257222101]],
  PRIMEM["Greenwich",0.0],
  UNIT["Degree",0.0174532925199433]],
 PROJECTION["Lambert_Conformal_Conic"],
  PARAMETER["False_Easting",0.0],
  PARAMETER["False_Northing",0.0],
  PARAMETER["Central_Meridian",-95.0],
  PARAMETER["Standard_Parallel_1",49.0],
  PARAMETER["Standard_Parallel_2",77.0],
  PARAMETER["Latitude_Of_Origin",49.0],
  UNIT["Meter",1.0]]

Best Answer

The problem you found is an already known bug, and has some tickets for GDAL:

http://trac.osgeo.org/gdal/ticket/4605

http://trac.osgeo.org/gdal/ticket/5191

To solve the problem, Set CRS for Layer to EPSG:3979, then Save As ... to another name.

With that, a .qpj file is added with the correct EPSG code, which will QGIS force to use that.


EDIT

Ogr2ogr seems to read the projection correctly, so running

ogr2ogr -t_srs EPSG:4326 waterwgs.shp AC_1M_Waterbodies.shp 

converts the shapefiles to a CRS that QGIS can load without misplacement.

Related Question