"Mel Collins" <[EMAIL PROTECTED]> writes: > As I haven't yet found any other way around this, my only recourse > seems to be to split the date columns into three, which just feels > wrong to me. Can anyone suggest a more elegant solution?
I believe the details of your application should have this requirement... But besides MySQL no database that I know of accepts such absurdities with dates. When I design an application that has dates my specs clearly say that dates should be fully specified or should be "NULL". For example, take a holiday table. When I designed mine the user could specify one specific full date (day, month and year) for a one time only holiday and he could set a boolean to True to specify that this date should be considered from there on making this a repeatable holiday. Taking this to your problem, maybe allowing the user to specify an unknown part and filling it with a value that will be ignored in your processing should solve the problem and make your application works with more stricter databases. How you'll design this depends on how many parts of the date may be unknown simultaneously: if only one then you could have a FK if more than one then you'd need a many-to-many relationship OR you could have more boolean fields... I'd think along these lines instead of using invalid dates. -- Jorge Godoy <[EMAIL PROTECTED]> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---