Escape of quotes

Tagged:
  • Klaus79
        5 years ago #17736

        How can quotes be escaped in Business Object Script.

        Normally with backslash in JavaScript but it does not work.

        “\”username: \”” results in \”username: \” instead “username: “

        Kahn
            Has successfully completed the online course Introduction
            Has successfully completed the online course Intermediate (200)
            Has successfully completed the online course Advanced (300)
          5 years ago #17738
          Up
          1
          Down
          ::

          Do you get your result in the TEST-Dialog? If so, then do not worry, this is just the stringified JSON version of the result in the dialog, the provided value is not stringified but provided directly.

           

          Klaus79
              5 years ago #17739
              Up
              0
              Down
              ::

              Yes, thinking about it yesterday I thought the same. I get following Output (not directly from a sql query but build up from script logic on my own based on a sql query. I think it’s correct.

               

              {
              “user_masterdata_vh”: [
              “{\”username\”:1, \”first_name\”:xxxx, \”last_name\”:xxxx, \”department\”:xxxx, \”email\”:xxxx}”,
              “{\”username\”:2, \”first_name\”:xxxx, \”last_name\”:xxxx, \”department\”:xxxx, \”email\”:xxxx}”
              ]
              }

            Viewing 3 posts - 1 through 3 (of 3 total)

            You must be logged in to reply to this topic.