newb: Scope Question

johnny rampeters at gmail.com
Fri Jun 22 18:53:54 EDT 2007


Scope of ids:
When I print "ids", it's always empty string '', as I have intialized
before.  That's not what I want. I want the ids to have
str(r['id']).join(',')

if res:
                ids = ''
                for r in res['key']:
                    ids = str(r['id']).join(',')

                print("ids: %s" %(ids))




More information about the Python-list mailing list