Reading huge number of json files in Python?

This is not about reading large JSON files, instead it's about reading large number of JSON files in the most efficient way. Question I am working with dataset from the Million song dataset. The data is available as a set of JSON-encoded te...
more »

2017-01-13 16:01 (1) Answers

Use JSON object as key in Java Map

Can i use json object as key in java maps. Following is want i am looking for: Map Object1 = { "Key1": "Value1"} Object2 = { "Key2": "Value2" } So that when i print map it should return { "Key1": "Value1"} : { "Key2": "Value2" } Here key and...
more »

2017-01-13 15:01 (0) Answers

Ajax JSON empty passing

To all whom it may concern (I am really just trying to reach the "please add more detail" limit) When passing data to the server as below the body is shown as empty. Server // POST method route'/pass', function (req, res) { console.log...
more »

2017-01-13 11:01 (2) Answers

Group together array elements

I have an array in PHP:- $arr = ["BX_NAME0","BX_NAME1","BX_NAME2","BX_categoryName0","BX_categoryName1","BX_categoryName2","BHA_categories0","BHA_categories1","BHA_categories2"] Here I want to group together elements based on same ending integer ...
more »

2017-01-13 11:01 (3) Answers

Jackson JavaTimeModule for Joda Time?

I would like to set global Jackson serialization setting for Local Date and use something like JavaTimeModule for java.time but for JodaTime's Local Date. Does something like JavaTimeModule exist for Joda Time? ...
more »

2017-01-13 10:01 (1) Answers

jsonpath expression for value match

Hi I have this test data data = [ { "company" : "abc", "CEO" : "john" }, { "company" : "xyz", "CEO" : "ron" } ] I want to query data by "ron", and want to get { "company" : "xyz", "CEO" : "ron" } ...
more »

2017-01-12 17:01 (1) Answers

Lodash code optimization/refactoring

This is the original JSON data: var data= [ { project: "ABC", area: 'Test', subArea: 'Dev', done: 10 }, { project: "ABC", area: 'Test', subArea: 'QA', done: 10 }, { project: "ABC", area: 'Test', ...
more »

2017-01-12 15:01 (3) Answers

Determine TimeZone from a JSON String?

I'm querying a JSON API that returns something like this: { "created_time": "2017-01-05T16:32:29+0100", "updated_time": "2017-01-11T09:38:41+0100", "id": "23842536731240607" } I need to store the times in UTC format, but in order to change t...
more »

2017-01-12 12:01 (2) Answers

Mapping JSON with multiple entries to an array

I have a JSON file with multiple entries that have same attribute names, but different attribute values, such as: { "name" : { "first" : "A", "last" : "B" }, "gender" : "MALE", "married" : false, "noOfChildren" : 2 }, { "name" : { "first" ...
more »

2017-01-12 10:01 (2) Answers

Post JSON data/object to API using reactive.js

I'm trying to add a JSON data/object to the API using ractive.js but i'm not getting any results. It shows me a response "no content". Not sure what I'm currently missing at the moment. I'm using ractive.js for this project. This is a sample code th...
more »

2017-01-12 08:01 (1) Answers

How to populate a Select type input php from Json

I'm building a zend framework project and I'm using php for the first time so my apolagies in advance if the question is too dumb or if it was already answered but I didnt find it. I'm trying to populate a select type input (dropdown list) with dat...
more »

2017-01-12 05:01 (2) Answers

SilverStripe how to return JSON headers

My controller method Foo() (which is called through AJAX request) prints a JSON to the page using json_encode($data). I'm trying to accompany the correct http headers by using header('Content-Type: application/json'); But from my browser developme...
more »

2017-01-11 20:01 (2) Answers

Parsing RSS with php to get a json feed

I need to convert a RSS feed from another domain and turn it into json. In order to circumvent cross-domain warnings, I'm parsing the RSS feed server side using this PHP proxy script. but somehow the response is in one long string. I would like ...
more »

2017-01-11 19:01 (2) Answers

ColdFusion handling AJAX JSON data

I am setting up a local API as an additional step in my external API call using AJAX. The sequence goes like this: Ajax call passes data to localAPI.cfm. Inside localAPI.cfm I have <cfhttp> to send the data to an external api. However, afte...
more »

2017-01-11 18:01 (1) Answers

Maximum size of Json handled by Jackson

Is there a limit to the size of JSON file which can be handled by Jackson? My JSON can be huge. Simple example: { "people": [ { "Name": "John Smith", "number": "123-456-789" }, {MILIONS OF OTHER PEOPLES} ], "cars": [MIL...
more »

2017-01-11 16:01 (1) Answers

How to bypass @JsonIgnore annotation?

I am trying to create a rest end point and using Swagger as UI representation. The pojo which I'm using it has a variable annotated with @JsonIgnore as shown below. @JsonIgnore private Map<String, Object> property = new HashMap<String, Obj...
more »

2017-01-11 11:01 (1) Answers

How to convert JSON to a Dataframe in python

I have the below JSON format, I need to convert this to a dataframe in python. Please let me know, how to go about it. JSON : User Patterns [{"Jane": [{"Thermostat": 20, "Days": [1, 2], "Hour": 6, "Minute": 43}], "John": [{"Thermostat": 18, "Day...
more »

2017-01-11 07:01 (1) Answers

How to handle Retrofit JSON dynamically

I'm getting following JSON response: "data" in object: "status": true, "data":{ //Some data } Sometimes it comes in array as: "status": true, "data":[ //Some data ] How to check data's response dynamically that, is object or array? *I'm...
more »

2017-01-11 07:01 (3) Answers

Plotting Line Graph with JSON data, Android

I'm total beginner in Android development and I'm doing app for class. My assigment is to display JSON data in application as text and graphs. I'm using Retrofit 2 to display it as text in one activity, but I'm having problems with graphs, I don't kn...
more »

2017-01-11 05:01 (1) Answers