0

Assuming the database and driver support nextset(), is there a way for me to use pandas to process multiple sets? I've only been working with pandas for a few days, so I'm not sure what I expect it to look like. My current workflow is df = pd.read_sql(sql_statement, db), slicing up df into sections as I process them consecutively. If I could somehow use cursor.nextset() instead, I would be able to simplify the stored proc significantly.

Mark
  • 999
  • 9
  • 19
  • 1
    what does `cursor.nextset()` return? a list of rows? how many? – Paul H Jun 27 '14 at 22:17
  • [cursor.nextset()](http://legacy.python.org/dev/peps/pep-0249/#nextset) returns a true value if there's another set, else None. It causes subsequent fetch* methods to pull from the next set in the list. – Mark Jun 28 '14 at 23:41
  • 1
    See here: http://stackoverflow.com/questions/36627048/pandas-io-sql-and-stored-procedure-with-multiple-result-sets – Max Masnick Jun 06 '16 at 16:38

0 Answers0