2
I have the following problem...
I am migrating a system, and in the same I own a client table
This table has a field called "cli_password", in which the customer’s password
To use Laravel authentication I had to create a column "password"
Now I need to replicate all the passwords in the column "cli_password" for the column "password".
But I can’t just duplicate the column cli_password and rename to password
Or perform a simple SQL to update the column password taking the value of cli_password for the field cli_password has no encryption.
Then I am obliged to go through all the fields of the table by performing the proper Hash.
But the table has more than 40 thousand records, and every time I query the screen returns blank, I can only select 5 thousand records through the "Chunk"
Would anyone have any suggestions or methods that are more efficient than doing multiple searches and updating their records?
Thank you so much for the answer, that’s right, I’m updating all the records picking from 5000 to 5000, I could also increase the connection time of Mysql (not to close after 30 seconds)
– Daniel Kuroski
It may be, but with this script it doesn’t hurt you to lose the connection by timeout. It will only get the records that are with null password. Updated, a hug.. Puts it in a url and runs when you give hahaha. Is mysql timeout? If php is set_time_limit(0)
– Magus