You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'źnr=012 AND bildes_db.aviokomp = bildes_aviokompanijas.ak AND bildes_db.mape = ' at line 1