date format

date format

Post by Vittori » Thu, 17 Jul 2003 15:31:03



Hello, I'm working with version 10 of SPSS. I have a numeric variable
related with birth date with this format *yyyyddmm*. I wish to change the
format in *yyyy*: what can I do?
Thanks,
Vittorio

--

 
 
 

date format

Post by Arthur J. Kendal » Mon, 21 Jul 2003 00:32:17


Is this what you mean?  It will give a numeric variable which will not
be treated as a date but contains the year.
numeric newvar (f4).
compute newvar = trunc(oldvar/10000).

Hope this helps.

Art

Social Research Consultants
University Park, MD USA
(301) 864-5570


> Hello, I'm working with version 10 of SPSS. I have a numeric variable
> related with birth date with this format *yyyyddmm*. I wish to change the
> format in *yyyy*: what can I do?
> Thanks,
> Vittorio


 
 
 

date format

Post by Fre » Tue, 22 Jul 2003 17:08:34


Assuming that the date of birth variable, is a pure number, and is
formated to F8, then you could run this, which will create a numeric
varaible year, just containing the year of birth

compute YEAR=number(substr(string(DOBVAR,f8),1,4),f4).


> Is this what you mean?  It will give a numeric variable which will not
> be treated as a date but contains the year.
> numeric newvar (f4).
> compute newvar = trunc(oldvar/10000).

> Hope this helps.

> Art

> Social Research Consultants
> University Park, MD USA
> (301) 864-5570


> > Hello, I'm working with version 10 of SPSS. I have a numeric variable
> > related with birth date with this format *yyyyddmm*. I wish to change the
> > format in *yyyy*: what can I do?
> > Thanks,
> > Vittorio

 
 
 

1. PB DATE format vs WIN.INI DATE format

Hello,

I've a question about PB date edit style.

eg. edit style of dw's column X is specified as (dd.mm.yy)

However, it results that the edit style is mm.dd.yy if
the win.ini section [intl].date = mm/dd/yy.

if win.ini section [intl].date = dd/mm/yy, the specified
(dd.mm.yy) edit style of PB's dw  is OK.

Can I develop a routine which can modify the windows's
date setting to be dd.mm.yy and how?

Thanks for your attention
Barry

2. UltiMail Lite and floppies

3. Date Format...Date to "Quarter"

4. Direct Client Need Sr .Net Application Developer in GA, 12 Months+ Contract

5. Coverting raw date format image file to GIF format

6. HP Deskjet 648c - Blinking orange light... please make it stop

7. Concatenating text into date format - (t3)

8. 3c batteries die with no warning

9. Lotus 1-2-3: How do I edit the date format?

10. Changing 1-Dec to 1-December (Date Format)

11. Date Format Conversion - United States -> United Kingdom

12. Excel97: date format

13. Date formatting problem