0

when i try the following

SELECT serials.device_id
FROM serials
LEFT JOIN performance
ON serials.device_id = performance.device_id

i get

(Error Static analysis:

1 errors were found during analysis.

Missing expression. (near "ON" at position 25) SQL query: Edit Edit

SET FOREIGN_KEY_CHECKS = ON;

MySQL said: Documentation

2006 - MySQL server has gone away)

Community
  • 1
  • 1
  • 3
    Possible duplicate of [Error (near "ON" at position 25) while importing Table for WORDPRESS ( A foreign key Error)](https://stackoverflow.com/questions/33974492/error-near-on-at-position-25-while-importing-table-for-wordpress-a-foreign) – Popeye Sep 06 '19 at 08:49

2 Answers2

0

This error message is rather confusing, but here's what it actually can mean:

  • Server side timeout without automatic reconnection set up.
  • Server has dropped a connection while you are using Windows client.
  • Client-side timeout.
  • Logic error in application.
  • You (or server admin) has killed a running thread with a command like mysqladmin kill.

Since I do not see the context (other than left join) of the error here, it would be nice if you posted more details:

  • Is this error happening when you are using mysql client, or, while you are trying to access MySQL programmatically?
  • Please state the operating system.
  • If you are accessing MySQL programmatically, is there any back trace?

Thanks in advance!

0

Edit your_file_name.sql and Search this line

ALTER TABLE `wp_posts`

Change from this

MODIFY `ID` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=33195;

to this

MODIFY `ID` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=33195;