Your answer is mentioned in your post. Passing a layer created with a definition query will provide subsets of the source data. You can then merge the outputs from each itteration. To make the subsetsAttribute your source data with an id indicating which subset it should be processed inusing, say, a field called FIELDand identifing features in, say, four groups identifed by letters.theList = ['a', 'b', 'c', 'd'] for each in theList: defQuery = "\"FIELD\" = '%s'" % (each) print defQuery
continue the loop bypassing the defQuery to CreateFeatureLayerthen pass the feature layer to the tool you want (Feature To Line, it seems).then delete the layer and continue by looping to the next letter in for loop.