[PATCH] Fix upgrade script for postgresql

Please report bugs here!

Moderator: Thorsten

Post Reply
bram
Posts: 19
Joined: Mon Aug 16, 2010 12:54 pm

[PATCH] Fix upgrade script for postgresql

Post by bram »

The upgrade script has several problems with postgresl:

a) postgresql does not support the syntax: alter table ... add ... after ....
This syntax is used to update the tables: 'faqdata' and 'faqdata_revisions'.
Fix this by creating a temporary table and copy'ing the data.

b) the 'faqsearches' was created with an id field of the type integer instead of serial.
No auto increment happens => errors when doing a second search


Attached is a patch that fixes this (0003-Fix-upgrade-script-for-postgresql.patch).
NOTE: this patch was originally written on 2.6.7. It is untested on the git HEAD.
You do not have the required permissions to view the files attached to this post.
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: [PATCH] Fix upgrade script for postgresql

Post by Thorsten »

Hi,

thanks for the patch, I reviewed it and added to phpMyFAQ 2.6.8.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Post Reply