Re: Parsing a single-level JSON file

2016-11-18 Thread mike . reider
the end result file looks like this cat fields.json {"myField1": {"id": "customfield_10600"}, "myField2": {"id": "customfield_11334"}, "myField3": {"id": "customfield_993434"}, etc etc -- https://mail.python.org/mailman/listinfo/python-list

Re: Parsing a single-level JSON file

2016-11-18 Thread mike . reider
On Friday, November 18, 2016 at 1:23:18 PM UTC-5, mike@gmail.com wrote: > hi all, > > Im reading in a JSON file that looks like this > > > [ >{ > "name":"myField1", > "searchable":true, > "navigable":true, > "custom":true, > "clauseNames":[ >

Re: Parsing a single-level JSON file

2016-11-18 Thread Peter Otten
mike.rei...@gmail.com wrote: > hi all, > > Im reading in a JSON file that looks like this > > > [ >{ > "name":"myField1", > "searchable":true, > "navigable":true, > "custom":true, > "clauseNames":[ > "cf[10190]", > "Log Details" >

Re: Parsing a single-level JSON file

2016-11-18 Thread MRAB
On 2016-11-18 18:23, mike.rei...@gmail.com wrote: hi all, Im reading in a JSON file that looks like this [ { "name":"myField1", "searchable":true, "navigable":true, "custom":true, "clauseNames":[ "cf[10190]", "Log Details" ],

Re: Parsing a single-level JSON file

2016-11-18 Thread John Gordon
In John Gordon writes: > In > mike.rei...@gmail.com writes: > with open("json.dat", "r") as fp: > data = json.load(fp) > for item in data: > if

Re: Parsing a single-level JSON file

2016-11-18 Thread John Gordon
In mike.rei...@gmail.com writes: > Im reading in a JSON file that looks like this > ... snip ... > Lets say I want to get the ID # of MyField1, how can I parse this with > json lib? Theyre all on the same level, not sure how to target it to