I was using PHP Mysql. Unfortunately, in a hurry I mistakenly added the below line in my code.
$sql=“update members set mem_name=‘$mem_name’” and I forgot to add where id=‘$id’
Hence, my entire database is changed to only one entry. Can you help me if I can undo this command and get my data back.
This is why testing on a non-production server is VERY VERY VERY important.
If you happen to have a backup of your database (And you should), you can import that backup. If you don’t have a backup, hopefully this serves as a lesson learned.