Re: BCE/CE Dates

2004-02-19 Thread Craig A. Finseth
...
   I have a, possibly not so unusual problem, with dates.  The standard MySQL datatime 
accounts for
   all dates starting between the year  and  inclusive.
...

Take a look at using Julian Day numbers.  This date form is used in
astronomy and general calendar conversions.

Every day has an integer number and it handles pretty much any date
you can imagine (as in the lifetime of the universe).

Just convert your dates to JDNs for storage and convert back for display.

Lots of code out there to do this.

Craig


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Outer join question

2004-01-20 Thread Craig A. Finseth
   First, you database design. You don't need to separate actresses from
   actors... Why do that? They are the same entity, a person, with only one
   different attribute: the genre. So, you should join them in one single
   table:

...
Actually, it is possible to be female and to be an Actor.  For
example, the Screen Actors' Guild officially considers the term
Actor to be gender-neutral and applies this term to all people.
...

Craig

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Storing mysql dates as an integer

2004-01-08 Thread Craig A. Finseth
   An unsigned int is probably more appropriate for timestamps than a
   signed int.

   Also note that the range for timestamps is 1970 until 2038 (or 2106? for
   unsigned ints), where DATE and DATETIME have a much greater range. Using
   a UNIX timestamp for birthdays might not be appropriate.

Many Unix systems are transitioning to a 64-bit timestamp: that should
cover most needs...(:-).

In the meantime, while there may be a some applications where it is
important to keep both the date AND time for a range outside of
1970-2038, I can't think of one outside of astronomy.

Most applications that need dates outside of that range don't need
much in the way of times in general and timezone adjustments in
particular.

When I am storing event timestamps, I use Unix 32-bit timestamps
(which are in GMT) as the base and either convert to local time for
printing or store a printed version (in -mm-ddThh:mm:ss- form)
in anotehr column where appropriate.  Storing the latter makes
date-based selection easy.

Craig


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



installation question...missing 'host.frm'

2003-09-10 Thread Craig A. Finseth
I am trying to install:

mysql-standard-4.0.14-sun-solaris2.8-sparc.tar

on a Solaris 8 system.  I am getting this message in the .err file:

030910 11:05:41  mysqld started
030910 11:05:41  InnoDB: Started
030910 11:05:41  Fatal error: Can't open privilege tables: Can't find file: 
'./mysql/host.frm' (errno: 13)
030910 11:05:41  Aborting

I haven't been able to find any reference to that file in any of the
MySQL documentation.  I've tried creating such a file, but the message
remains unchanged.

I am doing a little weird install.  The commands and scripts go into
/usr/local/bin and the database lives in /local/mysql.  I have added
symbolic cross links.

Anyone have any ideas?

Craig A. Finseth[EMAIL PROTECTED]
Firwood Consulting, Inc.[EMAIL PROTECTED]
1343 Lafond, St Paul MN 55104   +1 651 644 4027
USA http://www.firwood.net  +1 651 644 4027 fax (yes, same number)
A ship is safe in a harbor, but that's not what a ship is for--Adm Grace Hopper



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: installation question...missing 'host.frm'

2003-09-10 Thread Craig A. Finseth
   Errno 13 indicates that you have some permission issues.  Check the data
   directories you've set up to make sure that they are owned by the user/group
   mysql.

Thank you.  That was the problem.  The host.frm really threw me.

Craig

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]