-
We have bunch of birthdates in our DB that have 2000 as the century instead of 1900. What is the best way to change the century to 1900? I am not aware of an addcentury function or something like that and I don't know if converting it a string and doing a string replacement is the best approach. I apologize if this is a real basic question.
-
No, there is no add_century function. However, there IS an add_months function. So if you need to back up all of your dates by 100 years, then you could try:
UPDATE my_table SET dob = add_months(dob, -1200);
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|