Finding unique field names with different values

  • I am in a situation where I need to find out unique field names with different values in a table having 200+ columns.

    Let's say I have two rows with 200+ columns ( I exported these rows from Lotus Notes to SQL Server) I am not sure what columns makes unique of these rows. It's going to be tedious by checking each column values.

    Is there anyway I can write a squl query on these two rows which outputs column names which are having unique values.

    I would appreciate If anybody gives me hint about achieving desired result

     

  • R u trying to remove duplicates from the data, or are you trying to find the primary key?

  • I exported data from Lotus Notes. In Lotus Notes what there are doing is whenever they update a record they are creating new entry for the same record. When they are displying record on Lotus Notes, they are displaying only one record which is supposedly latest entry into the database. I have no access to their code to see how they are retrieving latest record. All I have to find is basically primary key or combination of fields which makes them unique. Since record has some 200+ fields, It's tough for me to identify unique fields.

  • You'll most likely have an id field (some sort of autonumber, but repeating). And you'll have a date column for the last entry... That'll be your key.

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

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