-5

I read that we are not allowed to have 2 columns that have 2 time-stamp. Like in my table "EMPLOYEE" I have 2 columns "CREATEDON" and "UPDATEDON" both are time-stamp.But MYSQL does not allows me to create it .But Why and what is the issue??

1 Answers1

0

In the new versions of mysql in a single table, multiple timestamps can be controlled. Refer the documentation.

Akash Lodha
  • 100
  • 9
  • My company currently earlier version and I need to know the reason for not allowing 2 timestamps for earlier. – mayank kumar Jul 11 '16 at 05:57
  • There is no "why" that will make any difference to you. It just _is_ that way. Asking why won't change the behavior, you have to accept it and find an alternative. There's no restriction on having multiple timestamp columns if your Java code sets their values, so find a workaround. – Jim Garrison Jul 11 '16 at 06:00
  • Tell them it is because it is enforced in 72 OP Codes compiled into the `C` daemon executable (or whatever else makes their eyes glaze over). – Drew Jul 11 '16 at 06:05
  • Ok ..but I guess there are various other DB that does not allow multiple time stamps it could be better that I know the reason :( – mayank kumar Jul 11 '16 at 06:18