Skip to Content.
Sympa Menu

freetds - RE: CONVERT and MSSQL

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Matthews Simon <sam AT knowledgepool.com>
  • To: "'TDS Development Group'" <freetds AT franklin.metalab.unc.edu>
  • Cc: "'mark AT slyguy.com'" <mark AT slyguy.com>
  • Subject: RE: CONVERT and MSSQL
  • Date: Mon, 11 Mar 2002 14:25:25 -0000

Title: Message
Although this is not a freetds issue I think what you are after is something more like this.
 
select * from table
where
left(convert(varchar(20),column_name,121),7) = '2002-03'
 
 
Simon

 
-----Original Message-----
From: Mark [mailto:mark AT slyguy.com]
Sent: 11 March 2002 14:06
To: TDS Development Group
Subject: [freetds] CONVERT and MSSQL

I am trying to convert a datetime column to varchar(20).

When I do this and try LIKE '%2002[-]03%' no results show up.

Any ideas of what I am doing wrong here?

 

Thanks,

-Mark

---
You are currently subscribed to freetds as: [sam AT knowledgepool.com]
To unsubscribe, forward this message to $subst('Email.Unsub')



Archive powered by MHonArc 2.6.24.

Top of Page