SQL update statement based on a formula?

in my table PostalCodes i need to select all Postalcodes from dbo.postalcodes where LEN = 4, and then add a leading 0 (zero) in front of value and re-update it.

For example, postal codes in the table that look like this:  7712  should actually be 07712

Anyone know how to do this?
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

Kyle AbrahamsConnect With a Mentor Senior .Net DeveloperCommented:
update postalcodes
set postalcode = '0' + postalcode
where len(postalcode) = 4
arthurh88Author Commented:
bah!  i should have figured this one out :)  Thanks!!
All Courses

From novice to tech pro — start learning today.