Cannot delete images, cannot upload image

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
Hello!
Moved to new hosting.
If i upload a image i got error: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY'

If i delete image from admin - i get error: An error occurred. Please try again later.
 

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
i dont delete file from hdd, i deleted image from Dashboard Images and get error - An error occurred. Please try again later.
after Reload page i saw this picture screenshot i sent you

Script deleted images from hdd but dont delete from sql
 
Last edited:

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
Could you help me with uploading files? When I upload a picture I get an error.
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY'
 

Attachments

Rodolfo

Chevereto Developer
Chevereto Staff
Joined
Oct 7, 2008
Messages
16,471
Points
237
Location
Chevereto HQ
Website
rodolfoberrios.com
Go to your conflicting db table and make sure to reclect an auto increment value = last id + 1.

Problem here is the missing auto increment value.
 

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
Fixed. (AUTO_INCREMENT for image_id) Uploads is working now. Thanks.

But second problem still existing..

Dashboard - Images - most recent - Delete an image (Error: An error occurred. Please try again later. )
Reload Page - and i see black square
attaches screenshots for show
 

Attachments

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
debug_level = 3
dasboard - settings- system - PHP error reporting = enable

But see nothing any php error except for "An error occurred. Please try again later."

I see something in error.log:

[Fri Feb 01 18:21:33 2019] [warn] [client 1**] mod_fcgid: stderr: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY' (LINE:467), referer: http://www.**.ru/dashboard/images
[Fri Feb 01 18:21:35 2019] [warn] [client 1***] mod_fcgid: stderr: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY' (LINE:467), referer: http://www.**.ru/dashboard/images
 

Mikelandjelo

Founder license
License owner
Joined
Mar 20, 2013
Messages
21
Points
53
Last issue about delete images. Uploading is working now correctly