-2

This is my dictionary

<QueryDict: {u'karnataka': [u'bangalore', u'tumkur']}>

I want to remove the QueryDict and i want as

{u'karnataka': [u'bangalore', u'tumkur']}
praveenjp
  • 25
  • 2
  • 8
  • It isn't a dictionary, it *is* a QueryDict... [What is the XY problem?](http://meta.stackexchange.com/questions/66377/what-is-the-xy-problem) – Sayse Feb 13 '17 at 10:23
  • ya i want to remove the "queydict", i want to iterate the dictionary – praveenjp Feb 13 '17 at 10:26
  • Just iterate over the query dict... again, what is the exact issue you're trying to solve. – Sayse Feb 13 '17 at 10:27
  • @Selcuk I also want the unicode for that dictionary, i just want to remove QueryDict – praveenjp Feb 13 '17 at 10:27
  • @Sayse,if i am trying to iterate then i am facing problem,iteration is not perfect,if it is in this way it is working just see this link http://stackoverflow.com/questions/42197322/how-to-iterate-dictionaries-and-save-in-to-the-database-in-python2-7/42198288?noredirect=1#comment71559816_42198288 – praveenjp Feb 13 '17 at 10:33
  • That question is equally as unclear as this one is, [ask] – Sayse Feb 13 '17 at 10:35

1 Answers1

-2
from django.utils import six

fields = dict(six.iterlists(request.POST))
print fields

I sorted out this works perfectly

praveenjp
  • 25
  • 2
  • 8