Thank You Everyone for spending time on my question. I could not have found the answer without having consulted you. But your insights revealed a lot and I finally found out why the statements were not working. It was simply because the
user_id column in my database was not set as UNIQUE. So, on Safe Mode, the WHERE clause made no sense to the program since it could'nt know for sure if there were 2 same
user_id entries. Hence the problems. Now it has been fixed. I decided to share this answer in case someone else gets caught up in this mess and wastes 12 hours on it :)
Thanks to all of you.