fetchall using chunksize