#7109 closed enhancement (fixed)

Setting layer alias in FieGDB layers.

Reported by: zbordas Owned by: warmerdam
Priority: normal Milestone:
Component: default Version: 2.2.1
Severity: normal Keywords:


We needed a way to explicitly set the layer alias when creating FileGDB layers. I added 2 lines of code to the existing source to honor if a layer alias if passed one in the configuration.

Simple change in ogr\ogrsf_frmts\filegdb\FGdbLayer.cpp : 2458:

/* Set the alias for the Feature Class, check if we received an explicit one in the options vector. */ if ( CSLFetchNameValue( papszOptions, "LAYER_ALIAS") != NULL ) {

std::string alias = CSLFetchNameValue( papszOptions, "LAYER_ALIAS");

CPLCreateXMLElementAndValue(defn_xml, "AliasName?", alias.c_str());

} else if (pszLayerNameIn != layerName) {

CPLCreateXMLElementAndValue(defn_xml, "AliasName?", pszLayerNameIn);


Attachments (1)

FGdbLayer.cpp (135.3 KB) - added by zbordas 14 months ago.
Modified source file.

Download all attachments as: .zip

Change History (2)

Changed 14 months ago by zbordas

Attachment: FGdbLayer.cpp added

Modified source file.

comment:1 Changed 14 months ago by Even Rouault

Resolution: fixed
Status: newclosed

In 40560:

FileGDB: add LAYER_ALIAS layer creation option (derived from patch by zbordas, fixes #7109)

Note: See TracTickets for help on using tickets.