Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Using local JSON data
01/10/2012
23:20
Avatar
carlskii
New Member
Members
Forum Posts: 2
Member Since:
01/10/2012
sp_UserOfflineSmall Offline

Hi,

I'm using CouchDB with JQGrid. My Couch data looks like this:-

{"total_rows":1662,"offset":0,"rows":
    [
    {"id":"338b79f07dfe8b3877b3aa41a5205e75","key":"2004-03-05T03:59:00+00:00","value": {"date":"2004-03-05T03:59:00+00:00","signature":"sig1","name":"name1"}},
    {"id":"338b79f07dfe8b3877b3aa41a540cf58","key":"2004-03-05T03:59:00+00:00","value": {"date":"2004-03-05T03:59:00+00:00","signature":"sig2","name":"name2"}},
    {"id":"338b79f07dfe8b3877b3aa41a566ca42","key":"2004-03-05T03:59:00+00:00","value": {"date":"2004-03-05T03:59:00+00:00","signature":"sig3","name":"name3"}},
    {"id":"15add79dd3efec4f34786d5f6a33ec5c","key":"2004-07-26T14:03:00+00:00","value": {"date":"2004-07-26T14:03:00+00:00","signature":"sig4","name":"name4"}}
    ] }

My JQGrid definition looks like this:

datatype: "local",
            height: 100,
            colNames:['key', 'signature', 'name'],
            colModel:[
                {name:'key',index:'key', width:80}
                {name:'value.signature',label:'Signature', width:100, align:"right"},
                {name:'value.name',index:'name', width:80}

            ]
caption: "Load Once Example"

However, the columns for the value.signature and value.name fields are always blank. Is there anything I'm missing here as I would have expected the JSON dot notation to work?

Any pointer would be much appreciated!

02/10/2012
03:32
Avatar
carlskii
New Member
Members
Forum Posts: 2
Member Since:
01/10/2012
sp_UserOfflineSmall Offline

OK found an answer to this here!

http://shanemccall.blogspot.co.....ample.html

 

shanemccall.blogspot.co.uk/2012/02/json-and-jqgrid-example.html

 

 

 

 

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
38 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information