mysql custombuild upgrade, gives count error

danny12345

New member
Joined
Nov 7, 2014
Messages
6
Hello,

I have updated mysql through custombuild 2.0.
I got a mysql query

Code:
  $s = mysqli_query($DBD->conn(),"SELECT 
							   v.lat,v.lng,v.postcode,v.winkelid,v.id as wid,v.plaats,v.adres,w.naam,w.id,
							   ( 6371 * acos( cos( radians(".$post_lat.") ) * cos( radians(v.lat ) ) 
							   * cos( radians(v.lng) - radians(".$post_lng.")) + sin(radians(".$post_lat.")) 
							   * sin( radians(v.lat)))) 
								AS distance 
								FROM vestigingen v, winkels w
								WHERE 
								 w.naam like '%".str_replace(' ','_',$_GET['query'])."%' AND w.id = v.winkelid
								HAVING distance < ".$_GET['straal']." 
								 ORDER BY distance") or die (mysqli_error($DBD->conn()));

Column count of mysql.proc is wrong. Expected 20, found 16. Created with MySQL 50051, now running 50544. Please use mysql_upgrade to fix this error.

Well, only this query gives a count error. When i try do do mysql_upgrade, then i get:

Looking for 'mysql' as: mysql
Looking for 'mysqlcheck' as: mysqlcheck
FATAL ERROR: Upgrade failed

When i want to login to mysql in shell i get:

ERROR 1045 (28000): Access denied for user 'blalba'@'localhost' (using password: YES)

Even with root it doesnt happen.

Couple of questions.

1) How to upgrade the tables?
2) It always shows that there is no PID file found when i upgrade. Even if i make it and give it 777 rights, after a restart, its disappeared, whats going on with this?
3)How do i safely re-install mysql? This is tha last options, since i need to backup all databases first.
4) Why does this count problem only occurs with that query?

Is there anyway to solve this problem?
 
Hello,

If MySQL does not accept root's and da_admin's password, try to run it with --skip-grant-tables option and upgrade tables with mysql_upgrade, then if it's needed change passwords. And soon as finish restart MySQL without --skip-grant-tables option.
 
Back
Top