Forum Discussion

snapuser's avatar
snapuser
New Contributor II
4 years ago
Solved

Setting up SSH account

Hi. I’m trying to set up an SSH Auth account in order to connect to an SFTP server. I’ve been given a .ppk file that was generated by PuttyGen and I’ve verified that I can connect to the SFTP serv...
  • j_angelevski's avatar
    2 years ago

    Hi Manzoor ,

    Depending on your input data, if you have a flat object, you can make all of the NULL fields blank by using the following expression:

    $.mapValues(val => val == null ? "" : val)

    This will iterate over each value for each key in the input data and depending if the value is null, it will return an empty string otherwise it will return the original value.

     

    Input data sample:

    [
        {
            "msg": "Hello, World",
            "num": 1,
            "field2": null
        }
    ]

     

    Output:

    [
      {
        "msg": "Hello, World",
        "num": 1,
        "field2": ""
      }
    ]