Reducing duplicate row because of different column values???

  • With the data example below I am trying to consolidate the duplicate rows by flattening the dealer and billcode, or putting those values in each of the columns instead of creating separate rows...

    74 MARTHA PATNE RIPLEY 1 23,327,76 ROTTINGDAM AAC SPRINGFIELD 3052 USA MPATRIP@AMERICANALARM.COM,MPATRIP@COMCAST.NET,PRIPLEY@ONECOMMUNICATIONS.COM

    arnumber customername dealer billcode addl_addr addr1 addr2 branch city zipcode country email defaultEmail

    39 SUSAN THALKER 22 71 BOTTOMWOOD RD AAC HAMMOND 02180-2703 USA SUWS3@COMCAST.NET 1

    56 ANN REBELLO 1 23 SHERIDAN AVE AAC MEDFORD 2155 USA NULL NULL

    58 DARRELL/PATTI SANDERS 60 20 DOTY AVENUE AAC DANVERS 1923 USA NULL NULL

    74 MARTHA PATNE RIPLEY 1 23 ROTTINGDAM DR AAC SPRINGFIELD 3052 USA MPATRIP@AMERICANALARM.COM 1

    74 MARTHA PATNE RIPLEY 1 327 ROTTINGDAM DR AAC SPRINGFIELD 3052 USA MPATRIP@COMCAST.NET 1

    74 MARTHA PATNE RIPLEY 1 76 ROTTINGDAM DR AAC SPRINGFIELD 3052 USA PRIPLEY@ONECOMMUNICATIONS.COM 1

  • Do you have a table with this structure?

    You should really read on normalization to properly design your tables.

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2

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

You must be logged in to reply to this topic. Login to reply