I'm trying to execute some raw sql. I found some code that did this:
from django.db import connection
cursor = connection.cursor()
cursor.execute(sql)
data = cursor.fetchall()
But the cursor.execute(sql) is blowing up with:
'Cursor' object has no attribute '_last_executed'
What is the best or proper way for me to execute my raw sql?
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment