On Nov 24, 8:53 pm, Greg Willits <[EMAIL PROTECTED]>
wrote:
> A typical example would be a Date Due field where a valid date = when it
> was done, a NULL value = not done yet that we know of, and a 0000-00-00
> value = it has been declared that it never will be done. Reports for
> this data must be able to distinguish between all three casees.

Ugly Hax and total abuse of a magic value, imo. Use a flag, as per
Josh's post.

> Additionally, I have legacy data/logic being replicated in Rails that
> expects to find and handle 0000-00-00 date values a specific way. AFAICT
> I have no way to continue the legacy data/logic systems using Rails as I
> cannot populate a date field with 0000-00-00 to remain consistent with
> existing data.

I don't think rails should be designed to play nicely with your
invalid legacy data, personally.  Designing the framework around
individual cases of legacy usage is a very, very bad idea.  Anyways, I
can imagine core members responses already, once they figure out what
you are asking: "Sounds like a great idea for a plug-in."  ;)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-core?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to