- Status Closed
- Percent Complete
- Task Type Bug Report
- Category Backend / Core
- Assigned To No-one
- Operating System UNIX
- Severity Medium
- Priority Very Low
- Reported Version Devel
- Due in Version Undecided
-
Due Date
Undecided
- Votes
- Private
FS#370 - Can`t empty trash in v2.36-rc2
Can`t empty trash in v2.36-rc2
System: FreeBSD 7.0-RELEASE
Programs:
postgresql-server-8.3.3
apache-2.2.9
php5-5.2.6
php5-bcmath-5.2.6
php5-pcre-5.2.6
php5-pgsql-5.2.6_1
php5-session-5.2.6
php5-xml-5.2.6
nginx-0.6.32
When I want to empty trash, in my browser I see red line at the top of page with one yellow point.
In system log:
postgres[67867]: [6-1] ERROR: operator does not exist: text = integer
postgres[67867]: [6-2] HINT: No operator matches the given name and argument type(s). You might need to add explicit type casts.
postgres[67867]: [6-3] STATEMENT: delete from user_preferences where key = 'watermark_photo' and value in (select v.identifier from photo_version v,
postgres[67867]: [6-4] photo p where p.identifier = v.photo and v.photo in (select p2.identifier from photo p2 where p2.folder = 1))
In trash.empty.php I found function nuke_photos
This function in include/common.php
So I comment section with expression 'watermark_photo'
// if ($result) {
// // Nuke any watermark preferences that use this photo
// $result = pg_query($database, "delete from user_preferences where key = 'watermark_photo' and value in (select v.identifier from photo_version v, photo p
// }
now I can empty trash. But ..
2008-08-01 20:55
Reason for closing: Fixed
Additional comments about closing: Confirmed fixed. There are probably similar bugs lurking, but we'll fix 'em when we get to 'em.
Loading...
Available keyboard shortcuts
- Alt + ⇧ Shift + l Login Dialog / Logout
- Alt + ⇧ Shift + a Add new task
- Alt + ⇧ Shift + m My searches
- Alt + ⇧ Shift + t focus taskid search
Tasklist
- o open selected task
- j move cursor down
- k move cursor up
Task Details
- n Next task
- p Previous task
- Alt + ⇧ Shift + e ↵ Enter Edit this task
- Alt + ⇧ Shift + w watch task
- Alt + ⇧ Shift + y Close Task
Task Editing
- Alt + ⇧ Shift + s save task
First, let me say thankyouthankyouthankyou for including lots of detail in this bug report.
Second, this bug is due to PG 8.3.x being a lot stricter than PG 8.2.x, and no longer performing implicit typecasting. I don't have a PG 8.3.x installation to test against, so there will probably be more bugs like this lurking in dark corners.
It's easy enough to fix, fortunately. Change:
... delete from user_preferences where key = 'watermark_photo' and value in (select v.identifier from photo_version v ...
to
... delete from user_preferences where key = 'watermark_photo' and value in (select text(v.identifier) from photo_version v ...
Let me know if this works. If so, I'll commit it for the 2.36-final release.
Yes. It works :)