I am wondering how can one add a coded field domain to a file geodatabase using
the FileGDB driver and File GDB API? Anytime I call AddFieldDomain it returns
false:
>>> coded_domain = ogr.CreateCodedFieldDomain("name", "desc", ogr.OFTString,
>>> ogr.OFSTNone, {1:'LOW'})
>>> driver = gdal.GetDriverByName("FileGDB")
>>> datasource = driver.Create(r'C:\output\test_domains.gdb', 0, 0, 0)
>>> datasource.AddFieldDomain(coded_domain)
False
>>> datasource.TestCapability(ogr.ODsCAddFieldDomain)
False
The documentation suggests that the FileGDB driver is capable of supporting
domains as of 3.3:
https://gdal.org/drivers/vector/filegdb.html?highlight=domains#field-domains
I am using gdal version 3.4.2.
Am I adding the domain incorrectly, or does this mean that domains are not
supported with the FileGDB driver?
Thank you,
Adam Gutonski_______________________________________________
gdal-dev mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/gdal-dev