diff --git a/sql_server/pyodbc/compiler.py b/sql_server/pyodbc/compiler.py index d40ad6d2..8f70cd69 100644 --- a/sql_server/pyodbc/compiler.py +++ b/sql_server/pyodbc/compiler.py @@ -78,7 +78,7 @@ def _cursor_iter(cursor, sentinel, col_count): Yields blocks of rows from a cursor and ensures the cursor is closed when done. """ - if cursor.db.supports_mars: + if not hasattr(cursor.db, 'supports_mars') or cursor.db.supports_mars: # same as the original Django implementation try: for rows in iter((lambda: cursor.fetchmany(GET_ITERATOR_CHUNK_SIZE)),