Modify

Opened 16 years ago

Closed 16 years ago

#4178 closed defect (fixed)

postgres bug fix [PATCH]

Reported by: Shane Caraveo Owned by: Michael Renzmann
Priority: normal Component: TracPastePlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

The latest change broke compatibility with the LIMIT clause, it needs to be LIMIT X OFFSET X rather than LIMIT X,X. Patch to come.

Attachments (1)

pasteplugin-limit.patch (515 bytes) - added by Shane Caraveo 16 years ago.

Download all attachments as: .zip

Change History (5)

Changed 16 years ago by Shane Caraveo

Attachment: pasteplugin-limit.patch added

comment:1 Changed 16 years ago by Michael Renzmann

Owner: changed from mitsuhiko to Michael Renzmann
Status: newassigned
Trac Release: 0.100.11

Thanks for the patch, will look at it.

comment:2 Changed 16 years ago by Michael Renzmann

Hmm... the LIMIT x,x syntax was also used before r4891. Did earlier revisions really work for you?

I did a quick test, and your patch seems to break the "Recent Pastes" functionality when using SQLite. I'll give it a closer look, but likely not before sometimes next week.

comment:3 Changed 16 years ago by Shane Caraveo

well, I svn updated today, after which I got the following error just accessing /pastebin:

Trac detected an internal error:

ProgrammingError: LIMIT #,# syntax is not supported HINT: Use separate LIMIT and OFFSET clauses.

Making the change allowed me to bring up pastebin, but I haven't tested beyond that. One other change on my end, updated pg 8.3.4 to 8.3.5.

comment:4 Changed 16 years ago by Michael Renzmann

Resolution: fixed
Status: assignedclosed

(In [4894]) TracPastePlugin: Correct use of LIMIT and OFFSET in limit_clause, to make it compatible (again?) with PostgreSQL. While at it, allow the offset to be set as additional filter when calling the method.

Thanks to mixedpuppy for reporting this issue.

Closes #4178.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Michael Renzmann.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.