CleanTalk / phpbb3.1-3.2-antispam

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MSSQL Incompatibility + Workaround

acalcutt opened this issue · comments

Hi Everyone.

I wanted to try running my phpbb forum on my Microsoft SQL server, which is a supported configuration by phpbb. However I found the cleantalk plugin is incompatible due to a few uses of "LIMIT" in sql, which is not supported by MSSQL.

Going through the code I found two files which used LIMIT.
acp\main_module.php
model\CleantalkSFW.php

I've tweaked these files a bit so the plugin now at lease works with MySQL and MSSQL here ( https://github.com/acalcutt/phpbb3.1-3.2-antispam )

At first I had just replaced the LIMITS with TOPS, but this would only have been MSSQL compatible. I ended up going through it again and trying to change it to use "sql_query_limit"

These are the files I modified
CleantalkSFW.php.txt
main_module.php.txt

Do you think there is any issue with this change I made to make it more compatible?

Hello.
It needs up to 3 workdays to investigate the issue.
Please, wait, we will contact you with the result.
Let us know about any updates

Thanks. I am using the files I posted on my forum at https://forum.techidiots.net/forum with Microsoft SQL 2019 and it seems to work there. I have also tested this with MySQL (MariaDB) and it seemed to work with that also.

Hi!

I have tested your code and it works. The version of the plugin with your code is in a separate branch called MS SQL-test.
In the next release of the plugin, we will test all the functionality again and add your code to the release.
Thanks!