How do I enter the date into a column in a specific way without having them add up?
Posted on 2008-10-30
I'm trying to insert a date plus "01" into my database in a very specific format. For example, if I were inserting this today I would insert 2008103001. I've tried the code below, but it simply adds my values together and would put 2050 into the field instead what I want. I'm sure it's something simple, but I'm too stupid to figure it out.
SET thisfield = YEAR(GETDATE()) + MONTH(GETDATE()) + DAY(GETDATE()) + 01