stsnider

Table compare output to variable or in-memory file

Discussion created by stsnider on Aug 2, 2012
Latest reply on Aug 7, 2012 by stsnider
I'd like to have the table compare function output to a in-memory file or variable instead of an actual text file.  Is that possible?

I tried using a table variable, but that errored.  I used a string variable and the process worked, but the string was empty.  Any suggestions?

This works:
arcpy.TableCompare_management(table1, table2, 'OBJECTID', 'ALL', '#', '#', '#', 'NO_CONTINUE_COMPARE', r'C:\Temp\compare_table2.txt')

This works, but the string is empty:
output_compare_string = ''
arcpy.TableCompare_management(table1, table2, 'OBJECTID', 'ALL', '#', '#', '#', 'NO_CONTINUE_COMPARE', output_compare_string)

Outcomes