[ php-blog-Bugs-3254006 ] categorytemplates & postgresql

"SourceForge.net" <[email protected]> Mon, 28 Mar 2011 20:35:49 +0000
Newsgroups gmane.comp.serendipity.trackers
Message-ID <[email protected]>
Bugs item #3254006, was opened at 2011-03-28 22:35
Message generated for change (Tracker Item Submitted) made by eazrael
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=542822&aid=3254006&group_id=75065

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Plugins
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Christoph Nelles (eazrael)
Assigned to: Nobody/Anonymous (nobody)
Summary: categorytemplates & postgresql

Initial Comment:
A friend told me that my s9y rss does not work anymore. The problem is a failing query: 
2011-03-28 22:17:36 CEST ERROR:  column "hide_rss" does not exist at character 1293
2011-03-28 22:17:36 CEST STATEMENT:  SELECT DISTINCT
                                    
                
                                    e.id,
                                    e.title,
                                    e.timestamp,
                                    e.comments,
                                    e.exflag,
                                    e.authorid,
                                    e.trackbacks,
                                    e.isdraft,
                                    e.allow_comments,
                                    e.last_modified,
                
                                    a.realname AS author,
                                    a.username AS loginname,
                                    a.email
                                     , e.body, e.extended
                                     
                                FROM
                                    serendipity_entries AS e
                                    LEFT JOIN serendipity_authors a
                                        ON e.authorid = a.authorid
                                    LEFT JOIN serendipity_entrycat ec
                                        ON e.id = ec.entryid
                                    LEFT JOIN serendipity_category c
                                        ON ec.categoryid = c.categoryid
                                    
                                    WHERE isdraft = 'false' AND (e.id NOT IN (SELECT e.id FROM serendipity_entries AS e
                                            LEFT JOIN serendipity_entrycat AS ec ON ec.entryid = e.id
                                            JOIN serendipity_categorytemplates AS t ON ec.categoryid = t.categoryid AND hide_rss = 1)) 
                                     
                                     
                                     ORDER BY timestamp DESC
                                      LIMIT 15

This in turn is caused by wrong database upgrades in plugins/serendipity_event_categorytemplates/serendipity_event_categorytemplates.php: checkScheme() as all SQL statements won't work on PostgreSQL as all the datatypes are MySQL ones. For example: 
"ALTER TABLE {$serendipity['dbPrefix']}categorytemplates ADD COLUMN hide_rss tinyint(1) default false";


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=542822&aid=3254006&group_id=75065

------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself; 
WebMatrix provides all the features you need to develop and publish 
your website. http://p.sf.net/sfu/ms-webmatrix-sf