Newbies keiron Posted December 21, 2004 Newbies Posted December 21, 2004 I have a standard date field. Some of the dates I am enetering are complete ie. dd/mm/yyy and will display fine. Some of the dates I have are year only. I cannot enter year onlt without getting an error. I'm sure there is an easy way to do this :-) Cheers
-Queue- Posted December 21, 2004 Posted December 21, 2004 2004 is not a date; it is either number or text. So a field containing only the year should be either number or text, not date.
Newbies keiron Posted December 21, 2004 Author Newbies Posted December 21, 2004 I know about the use of Text as a field rather than Date ... problem is I need it to be a Date field for those dates I have ... is there a way of enetering wild cards or something similar so thatFMP will let me enter incomplete dates?
-Queue- Posted December 21, 2004 Posted December 21, 2004 Incomplete dates are not dates and so cannot be used in date fields. The only semi-exception is that FM will assume the current year if you enter month and day but no year. 12/1 will convert to 12/1/2004. But it makes no sense to enter a month and year or day and year and end up with a date result.
Oldfogey Posted December 22, 2004 Posted December 22, 2004 Keiron, How can you use a genuine Date field for only some of your records? If you are sure you can separate the duds from the real dates, use a text field and, when you've identified your genuine values, use the TextToDate function.
Søren Dyhr Posted December 22, 2004 Posted December 22, 2004 Lord help me to make my posts as perfectly clear as I wish others were. Hmm...Read this: http://www.cs.tut.fi/~jkorpela/wiio.html Regards --sd
Søren Dyhr Posted December 22, 2004 Posted December 22, 2004 2004 is not a date; it is either number or text. So a field containing only the year should be either number or text, not date. This is only half as daft as it seems at first sight, one date consists of 24 hours while a year consists of 8760 hours approximately - both representing commonly agreed abstractions for timespans. The problem is that while a day is the time it takes to make earth rotate around it own axis, is the less grained matters as month and year due to approximations including leap days more tricky measures to adjust the way the earth travels around in it's solarsystem. A solution must be to allow the user to enter specific dates as well as years in textfields by counting delimiters and construct keys like Edoshins SmartRanges keys accordingly. While letting the entry of 2004 mean the entire year and incomplete dates such as 12/21 mean the date at present year... --sd
transpower Posted December 22, 2004 Posted December 22, 2004 Soren: Well, then, use two separate fields: one would be a regular date field and another would be for whole years or whole months or days.
Barbecue Posted December 23, 2004 Posted December 23, 2004 If I needed to do something like this in FileMaker, I would just store the day, month, and year values each in a separate number or text field, and compute the actual date values as needed. Then you could search for blank months, or blank days, etc... Depending on how the data is being used, it could make sense to have a date field stand for a whole year. I've seen things like this in project management apps before. The usual way to do this is to assume that incomplete dates actually represent an arbitrary real date. For example you could define a year-only entry as actually meaning the first date of the year, and assume an implicit 01/01 on the front of any year-only date. This is really no different than assuming the current year for dates that don't include the year, it's just not as intuitive. The problem is that the users must understand what the entries are for, so it's really not appropriate in a general-use application IMHO.
Oldfogey Posted January 3, 2005 Posted January 3, 2005 sd, Thanks for the read. It seems my prayer can njever be answered!
Recommended Posts
This topic is 7333 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now