LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (July 2010, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Fri, 16 Jul 2010 20:49:34 -0500
Reply-To:   Craig Johnson <cjohns38@GMAIL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Craig Johnson <cjohns38@GMAIL.COM>
Subject:   Re: Character Date Conversion in PROC SQL
Comments:   To: Joe Matise <snoopy369@gmail.com>
In-Reply-To:   <AANLkTimmu8VE_TSmzSdBrOct8wxvthTU44nS1avBSWMe@mail.gmail.com>
Content-Type:   text/plain; charset=ISO-8859-1

My newness is showing! I'm connecting through a libname using an OLEDB connection.

On Fri, Jul 16, 2010 at 5:00 PM, Joe Matise <snoopy369@gmail.com> wrote:

> Bit more detail - are you running just PROC SQL not connecting to anything > (using LIBNAME access, basically), or is this passthrough to a server (using > CONNECT TO)? > > If it's just PROC SQL not connected to anything, then INPUT will work > fine. But if it's passthrough, you either need to do it in the first part > of the passthrough: > > proc sql; connect to ... ; > create table A as select a,b,c,input(d,'mm/dd/yyyy') as d from connection > to ... ( select * from whatever); > quit; > > or you need to use your local database's terminology inside the connection > to ... statement (cast, to_num, etc.). > > -Joe > > > On Fri, Jul 16, 2010 at 4:54 PM, Craig Johnson <cjohns38@gmail.com> wrote: > >> I need to convert some dates stored in a database (10-10-2010 and >> 10/10/2010) from character fields to numeric fields. What's the best way >> to >> go about this in PROC SQL? >> > >


Back to: Top of message | Previous page | Main SAS-L page