i encoutered a problem while setting up my REST request in Talend, to query data from the Bubble API.
The returned type is JSON, but some of the default names for attributes contains spaces (Modified Date, Created By), which seem incompatible with JSON parsers (the JSON parser does not allow it, the XPath one does not event open the file).
[com.jayway.jsonpath.InvalidPathException: Space not allowed in path]
As it does not seem posible to edit built-in field names (and replace spaces by underscores), does anyone know a turnaround for this ?
So it sounds like you are pulling data from Bubble into Talend, right? What are you trying to do with the returned data? It’s perfectly valid to have spaces in JSON field names. It’s not entirely clear that parsing is the problem.
Exact @sudsy , i am pulling data from Bubble into Talend through a tRESTclient, then parse the fields with a tExtractJSONfields using loop Jsonpath query “$.response.results[*]” and Json query “Modified Date”.
Everything works fine with all other queries including “_type” and “_id”.
On Talend forum, i read the following : " It is not allowed to contains a space in the column name, because Talend studio is a Java code generator, each column will be variable in the job class. A variable name can not contains a space in Java. You need to replace the space with other character such as “_”.
OK, then that’s a Talend requirement/limitation. It has nothing to do with parsing the JSON (which seems to be happening just fine).
I’m not familiar with Talend, but if you can “intercept” the JSON and insert an underscore (or simply omit those fields if you don’t need them), that might be a way to go. (I don’t know if/how you can change the name of built-in fields on the bubble end.)