Professional Web Applications Themes

Vague dates - MySQL

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....

  1. #1

    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.

    strawberry Guest

  2. #2

    Default Re: Vague dates

    varchar!

    == Quote from strawberry (com)'s article 

    lark Guest

  3. #3

    Default Re: Vague dates

    strawberry wrote:
     


    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
    Brian Guest

  4. #4

    Default Vague dates

    I'm sure I posted this message earlier today, so let me know (and
    apologies) if it shows up somewhere...

    I'm creating a table of antique objects, including their year of
    manufacture. In some cases the year will be precisely known - '1855'
    or '1930', say. In other instances it will be vaguer - 'circa 1850' ,
    '1835 - 1860' or 'mid-19th century'. Just wondering if anyone had any
    thoughts on how best to represent this in the table. One idea I had
    was simply to provide, in each case, a mid-range value in one column
    and a margin of error or 'tolerance' in another - but I'm open to
    suggestions.

    Any thoughts - or, better yet, a definitive answer, appreciated.

    strawberry Guest

  5. #5

    Default Re: Vague dates

    strawberry wrote: 

    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
    Chad Guest

  6. #6

    Default Re: Vague dates

    On Apr 25, 2:18 am, Chad Hanna <co.uk> wrote: 
    >
    > 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[/ref]

    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

    strawberry Guest

Similar Threads

  1. Server stops responding to requests, vague error
    By fleshlight in forum Macromedia ColdFusion
    Replies: 0
    Last Post: April 9th, 08:40 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139