json object unescape quotes on field

(3 posts) (2 voices)

Tags:

No tags yet.

  1. maron, Member

    Hello.

    I've created a few webservices using the json export functions. However I sometimes have fields where I have formatted JSON myself using functions - these fields are passed through functions which parse the data and output well formed json.

    However when using export=json&json_force_object=1 then I get this field with all the quotes escaped (\") - thus after I get the JSON field on the client side I need to run that one field through JSON.parse again - which seems unneccessary.

    Would there be a way to add a dbr.json: command that would be parsed similar to dbr.html: but in this case pass the data onwards unescaped when the json export options are used?

    Maron

  2. myDBR Team, Key Master

    Sure,
    we can take a look at it.

    --
    myDBR Team

  3. myDBR Team, Key Master

    You can CAST the column to JSON. In the databases where there is no native JSON support (MariaDB, Sybase) you can use command dbr.export.json.

    --
    myDBR Team


Reply

You must log in to post.