splititng multiple enries string RRS feed

  • Question

  • Hi All,

    I have 2 table like below.

          Table1                                                  Table2

    Id  Countryname  UpdatedNames                    Countryname  Description                               
    1      IND                                                                  JAP        Japan
             US                                                                  IND         India
              JAP                                                                AFR         Africa
                                                                                  GER         Germany
    2        AFR                                                               Pak         Pakistan                              
             GER                                                                SRI         Srilanka
             PAK                                                            US         UnitedStatesofAmerica

     Table1 column have multiple entries in ID no-1 or Idno-2...etc.. So we have to split these first and join these data with table2 and get those data and append those values to ID no-1 or Idn0-2..etc with multiple entries in Updated names column. its not like 1 to 1 join.

    I am Expecting Like following mean Description needs to update in UpdatedNames column with respected values.                  


    Id  Countryname  UpdatedNames                                         
    1     IND          India                      
          US           UnitedStatesofAmerica                          
          JAP          Japan                       
    2    AFR         Africa                           
         GER         Germany                        
         PAK         Pakistan                              
         SRI         Srilanka

    do we have any function or Query. Could you please help on this.



    Wednesday, November 20, 2019 7:25 AM