Vague dates

This is a discussion on Vague dates within the MySQL Database forums, part of the Database Forums category; I'm creating a table of objects, including their year of manufacture. In some cases the year of manufacture will ...


Go Back   Usenet Forums > Database Forums > MySQL Database

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-24-2007
strawberry
 
Posts: n/a
Default Vague dates

I'm creating a table of objects, including their year of manufacture.
In some cases the year of manufacture will be very precise, '1855',
say. In other cases the year will be much more vague - 'circa 1830',
'1780 - 1820' or even 'early 19th century'. Indeed, as the objects get
more ancient, I can well imagine that their ages become much less
precise. Just wondered if anyone had any suggestions about ways of
storing this kind of information.

Reply With Quote
  #2 (permalink)  
Old 04-24-2007
lark
 
Posts: n/a
Default Re: Vague dates

varchar!

== Quote from strawberry (zac.carey@gmail.com)'s article
> I'm creating a table of objects, including their year of manufacture.
> In some cases the year of manufacture will be very precise, '1855',
> say. In other cases the year will be much more vague - 'circa 1830',
> '1780 - 1820' or even 'early 19th century'. Indeed, as the objects get
> more ancient, I can well imagine that their ages become much less
> precise. Just wondered if anyone had any suggestions about ways of
> storing this kind of information.


Reply With Quote
  #3 (permalink)  
Old 04-24-2007
Brian Wakem
 
Posts: n/a
Default Re: Vague dates

strawberry wrote:

> I'm creating a table of objects, including their year of manufacture.
> In some cases the year of manufacture will be very precise, '1855',
> say. In other cases the year will be much more vague - 'circa 1830',
> '1780 - 1820' or even 'early 19th century'. Indeed, as the objects get
> more ancient, I can well imagine that their ages become much less
> precise. Just wondered if anyone had any suggestions about ways of
> storing this kind of information.



I presume you wish to search by date at some point.

Perhaps store a mid-point and a range.

So 1780-1820 would be mid-point = 1800, range = 20 (i.e. +/- 20 years from
mid-point).

Then you can query it using mid-point - range and mid-point + range.


--
Brian Wakem
Email: http://homepage.ntlworld.com/b.wakem/myemail.png
Reply With Quote
  #4 (permalink)  
Old 04-25-2007
Chad Hanna
 
Posts: n/a
Default Re: Vague dates

strawberry wrote:
> I'm creating a table of objects, including their year of manufacture.
> In some cases the year of manufacture will be very precise, '1855',
> say. In other cases the year will be much more vague - 'circa 1830',
> '1780 - 1820' or even 'early 19th century'. Indeed, as the objects get
> more ancient, I can well imagine that their ages become much less
> precise. Just wondered if anyone had any suggestions about ways of
> storing this kind of information.
>


I store the start and end years as integers. This makes comparison with
another potentially overlapping period reasonably straightforward.

Chad

--
Chad Hanna
Systems Developer FamilyHistoryOnline www.familyhistoryonline.net
FreeBSD Apache MySQL Perl mod_perl PHP
Reply With Quote
  #5 (permalink)  
Old 04-26-2007
strawberry
 
Posts: n/a
Default Re: Vague dates

On Apr 25, 2:18 am, Chad Hanna <c...@chadhanna.co.uk> wrote:
> strawberry wrote:
> > I'm creating a table of objects, including their year of manufacture.
> > In some cases the year of manufacture will be very precise, '1855',
> > say. In other cases the year will be much more vague - 'circa 1830',
> > '1780 - 1820' or even 'early 19th century'. Indeed, as the objects get
> > more ancient, I can well imagine that their ages become much less
> > precise. Just wondered if anyone had any suggestions about ways of
> > storing this kind of information.

>
> I store the start and end years as integers. This makes comparison with
> another potentially overlapping period reasonably straightforward.
>
> Chad
>
> --
> Chad Hanna
> Systems Developer FamilyHistoryOnlinewww.familyhistoryonline.net
> FreeBSD Apache MySQL Perl mod_perl PHP


Brian, Chad,

Thanks for the suggestions - I think the idea of a mid-point and
tolerance will be the simplest for me to maintain.

Cheers

Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 05:22 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0