# Database Discussions > Microsoft SQL Server 2008 >  Begin End with If statement

## rainydays

Hello team,

Is Begin and End needed for each if statement?

If ('A'>'B')

Begin
SELECT 'The first Value'
End

Else
Begin
SELECT 'The second'
End

Regards,
RainyDay

----------

