i have requirement where i have converted row values into columns but what i'm trying to remove null rows and show only data 

```
declare @t table (id int,keys varchar(10),val varchar(10))
insert into @t (id,keys,val)values (1,'name','hulk'),(2,'age','22'),(3,'name','ironman'),(4,'age','35')
;with CTE AS (
Select  [name],CAST([age] AS INT)age from (
select id,keys,val from @t )t
PIVOT(MAX(val) for KEYS in ([name],[age]))P

GROUP BY [name],age)
Select  (C.name),(C.AGE) from CTE C 
LEFT JOIN CTE cc ON c.age = cc.age AND c.name = cc.name

```

result :

```
name    AGE
NULL    22
NULL    35
hulk    NULL
ironman NULL

```

Desired result set :

```
name    AGE
hulk    22
ironman 35

```