AnsweredAssumed Answered

Problem with 'Dissolve' and Field statistic

Question asked by Gabino011 on Jan 15, 2015
Latest reply on Jan 16, 2015 by Gabino011

Hi All - I am trying to use dissolve_management applying it to obtain a field statistic {MAX} from the field [TIME]. The format of the field 'Time' is numeric (float).  I am doing this for a set of FCs running through a For-loop. When I remove the field statistic option/constraint from the code it runs perfectly, but I need that Time statistic, as well as other statistics from other fields, but I figured if I get it for one I could get them for the others later.


The code gets stuck on the first FC of the loop.  Thanks much for any insight on this !!


# Import system modules

import arcpy, os

from arcpy import env


# Set environment settings

env.workspace = r"C:\GIS\Track1\1_Orig\T_shp\shp"


# Set local variables

folder = r"C:\GIS\Track1\1_Orig\T_dis"

dissolveFields = ""

wildcard = ""

fctype = ""



    infcs = arcpy.ListFeatureClasses(wildcard, fctype)

    print infcs

    for fc in infcs:

        outfcs = folder + os.sep + fc

        print outfcs

        #outfcs = os.path.join(folder, fc)

        arcpy.Dissolve_management (fc, outfcs, dissolveFields, ["TIME",{MAX}],




    print arcpy.GetMessages(2)