I am developing a TSQL query for SQL Server 2008 R2. I am trying to develop this query to identify one record / client. Because some of these values are NULL, I am currently d
Try grouping by group_profile_id and selecting MAX() of every other column. MAX will select the non-null value (if one exists, or the maximum if multiple exist) of each repeating entry. Although the more efficient solution would involve sorting out additional NULL rows in the data, from first glance.