Skip to main content

Niall Gallagher

Member since Jun 9, 2009

Recent Blog Comments By Niall Gallagher

  • Getting Only the Date Part of a Date/Time Stamp in SQL Server

    Posted on Jun 9, 2009 at 10:12 AM

    I'd recommend avoid strings entirely. select month(cast(convert(varchar,getdate(),105) AS datetime)), month(cast(convert(varchar,getdate(),101) AS datetime)) In my UK locale this returns 9 and 6 for the month values -- i.e. the month() function returns an incorrect value because the code converted... read more »

I believe in love. I believe in compassion. I believe in human rights. I believe that we can afford to give more of these gifts to the world around us because it costs us nothing to be decent and kind and understanding. And, I want you to know that when you land on this site, you are accepted for who you are, no matter how you identify, what truths you live, or whatever kind of goofy shit makes you feel alive! Rock on with your bad self!
Ben Nadel