Hi everyone,
This is my first post here, I've recently started working as a developer and part of my job is managing the countless databases my company has. This has been a great resource, but I'm stuck on a date format issue and can't find an answer by searching.
The issue I'm having is converting a mm/dd/yyyy date to mm/dd/yy. As a preface, I am using Windows and the US date format. This database's main table is linked to a report that runs every month with account information. The data in the table is in mm/dd/yyyy format, which is good. The problem is, my company likes to have the mm/dd/yy format in their reports as it looks cleaner.
There is a form that the user enters data into, and then from there they launch the report. I have set the 'Format' property in the text box's property sheet in both the form and report to 'mm/dd/yy' to reflect this. This works fine until the dates are greater than 2049. For example: 10/07/40 is fine, but 10/07/2050 is not.
I'm sure I'm overthinking it, but the only thing I can think of is using one of the string functions like LEFT, MID, or RIGHT to remove the century from the date if it's present. Any ideas would be greatly appreciated. If I can clarify the question or provide more details please let me know.
Thanks,
Ross
This is my first post here, I've recently started working as a developer and part of my job is managing the countless databases my company has. This has been a great resource, but I'm stuck on a date format issue and can't find an answer by searching.
The issue I'm having is converting a mm/dd/yyyy date to mm/dd/yy. As a preface, I am using Windows and the US date format. This database's main table is linked to a report that runs every month with account information. The data in the table is in mm/dd/yyyy format, which is good. The problem is, my company likes to have the mm/dd/yy format in their reports as it looks cleaner.
There is a form that the user enters data into, and then from there they launch the report. I have set the 'Format' property in the text box's property sheet in both the form and report to 'mm/dd/yy' to reflect this. This works fine until the dates are greater than 2049. For example: 10/07/40 is fine, but 10/07/2050 is not.
I'm sure I'm overthinking it, but the only thing I can think of is using one of the string functions like LEFT, MID, or RIGHT to remove the century from the date if it's present. Any ideas would be greatly appreciated. If I can clarify the question or provide more details please let me know.
Thanks,
Ross