Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to know insert date for a row in mysql database [duplicate]

Is there any way to find insert date for a row in mysql database without adding a date column...?

I have some records of clients query in mysql database I forgot to add date column to track insert date and time. I need to know when row is inserted in table.

like image 310
Sanjay Singh Avatar asked Dec 13 '14 15:12

Sanjay Singh


People also ask

How can I find the duplicate row counts from a specific table in MySQL?

Find Duplicate Row values in One ColumnSELECT col, COUNT(col) FROM table_name GROUP BY col HAVING COUNT(col) > 1; In the above query, we do a GROUP BY for the column for which we want to check duplicates. We also use a COUNT() and HAVING clause to get the row counts for each group.


1 Answers

MySQL does not store timestamps per rows. If you did not save it yourself (e.g., by adding a timestamp column to your table and populating it with a trigger), there's no way to retrieve this information from the database.

like image 141
Mureinik Avatar answered Sep 28 '22 18:09

Mureinik