How to merge two rows in a grid

i have requirement that how many of country we select those many rows are populating in grid ,i want to restrict those many rows to single row.any suggestion 

  Discussion posts and replies are publicly visible

Parents Reply
  • a!localVariables(
      local!selectedCountrys,
      {
        a!multipleDropdownField(
          label: "Country",
          placeholderLabel: "---select---",
          choiceLabels: {
            "Australia",
            "Newzeland",
            "India"
          },
          choiceValues: {
            "Australia",
            "Newzeland",
            "India"
          },
          value: local!selectedCountrys,
          saveInto: local!selectedCountrys,
          
        ),
        a!gridField(
          label: "Slected Country's",
          labelPosition: "ABOVE",
          data: if(
            or(
              isnull(
                local!selectedCountrys
              ),
              length(
                local!selectedCountrys
              ) = 0
            ),
            {},
            {
              {
                name: tostring(
                  local!selectedCountrys
                )
              }
            }
          ),
          columns: {
            a!gridColumn(
              label: "Names",
              sortField: "name",
              value: fv!row.name
            )
          }
        )
      }
    )

    can you check this code one 

Children
No Data