Python in model do I output a table?

Discussion created by seanstock on Aug 22, 2011
Latest reply on Dec 7, 2013 by agrineersumit
Hello all. I am having trouble figuring out how to return a table from a python script in model builder. I want to take a table view in and output a recordset. I was hoping something like the below would work, but it does not.

table = arcpy.GetParameter(0)
result = table
optable = result.getOutput(0)

If anyone could tell me the magic line that will let me get the above to work, I would greatly appreciate it.

I do intend to modify the table later, but right now inputting and outputting an identical table would be a huge step forward.

Thanks in advance to whoever reads this!