AnsweredAssumed Answered

arcpy.LoadData_production - module object has no attribute

Question asked by forbesrs on Aug 25, 2019
Latest reply on Aug 28, 2019 by dan_hopkins-esristaff

I am attempting to use the Production Mapping Data Load tool to copy data from one database into another with a differing schema.  Something I've done manually several times, but would prefer to script it out to save some time.  Unfortunately I've run into some issues, and was hoping someone may point me in the right direction.  

 

Code Sample:

 

import arcpy

try:
    if arcpy.CheckExtension("Foundation") == "Available":
        arcpy.CheckOutExtension("Foundation")

    else:
        raise LicenseError

    arcpy.LoadData_production(crossReference, sourceDatabase,
                              targetDatabase, logRowErrs)

except LicenseError:
    "Production Mapping License unavailable"

 

Returns:

AttributeError: 'module' object has no attribute 'LoadData_production'

 

It is worth mentioning this is the result when I execute the code from a *.py - when I copy and paste the code into an ArcMap Python window it runs fine. 

 

I would appreciate any guidance!

 

V/R,

Forbes

Outcomes