Q:

SQL: How to replace one with two?

I have a table "first":

I am trying to write a query.
    If first.type = 'MM'

    then replace this line in two new lines

    where first.type = 'HH' and first.type = 'VV'.

For example : The line where first.type = 'MM':

I want to replace this line like that:

And the result:

Does someone have an idea on how this can be done?
I'm using MS SQL Server Management Studio Express.

A:

select id,freq,parity,line,type,gain,obdim from [first] where type<>'MM'
union
select id,freq,parity,line,'HH' as type,gain,obdim from [first] where type='MM'
union
select id,freq,parity,line,'VV' as type,gain,obdim from [first] where type='MM'

