From: Dean on 25 Jul 2010 08:49 I'm pulling date data from a Cube in character format, i.e. 2007 July 2007 August 2007 September I'm trying to split this into a monyy7 date format using PROC SQL. Any suggestions?
From: Arthur Tabachneck on 25 Jul 2010 12:52 Dean, You might be able to use something like: data have; input have_date & $20.; cards; 2007 July 2007 August 2007 September ; proc sql; create table want as select input(catt('1', substr(scan(have_date,2),1,3), scan(have_date,1)),date9.) as want_date format=monyy7. from have; quit; HTH, Art ------------- On Jul 25, 8:49 am, Dean <dean.par...(a)gmail.com> wrote: > I'm pulling date data from a Cube in character format, i.e. > > 2007 July > 2007 August > 2007 September > > I'm trying to split this into a monyy7 date format using PROC SQL. Any > suggestions?
From: Dean on 26 Jul 2010 04:05 That helps a lot - thanks very much Art On Jul 26, 2:52 am, Arthur Tabachneck <art...(a)netscape.net> wrote: > Dean, > > You might be able to use something like: > > data have; > input have_date & $20.; > cards; > 2007 July > 2007 August > 2007 September > ; > > proc sql; > create table want as > select input(catt('1', > substr(scan(have_date,2),1,3), > scan(have_date,1)),date9.) > as want_date > format=monyy7. > from have; > quit; > > HTH, > Art
|
Pages: 1 Prev: SAS macros Next: No bugs reported for the Spectre Clinical reporting system in six months |