Page 1 of 1

MS SQL Server users - here's the latest bug roundup

Posted: Wed Oct 17, 2018 2:40 pm
by gsmaclean
It seems like nobody bothers to regression test PHPBB on MS SQL Server, so every time there is a new release, I'm left with a site that either doesn't upgrade, doesn't function, or functions incorrectly. I then spend hours finding all the latest bugs in the SQL Server driver code, fixing them, and posting bug reports in the tracker. I am a developer by trade, so I can do this, but I doubt most PHPBB administrators are going to be able to diagnose and fix these problems.

I know most people who have problems are going to come here, not go searching through the bug tracker. So I thought I would post the latest ones I have found, in order to get your 3.2.3 board running correctly.

Forum crashes if upload directory > 2 GB

I reported this bug back in May of this year, but no activity has been done on it, and the bug still exists in the current 3.2.3 version of PHPBB. If you have more than 2 GB of files uploaded in your forum Files directory, PHPBB will crash whenever anyone tries to upload another file. This is due to a missing function in the MSSQL database driver, causing a cast to an incorrect data type. The ticket (including the fix) can be seen here:

https://tracker.phpbb.com/browse/PHPBB3-15665

Exception running PHPBB 3.2.x under PHP 7.2.x and SQL Server

PHPBB 3.2.x is supposed to support PHP 7.2.x, however it fails when running under SQL Server because SQL Server result sets under earlier versions of SQL Server don't have Count properties (newer versions can support it, but you must use cursors, which makes queries slow), and the mssqlnative.php code assumes that they all do. The ticket (with the fix) is here:

https://tracker.phpbb.com/browse/PHPBB3-15844

Unicode double encoding

Lastly, a change was made to the mssqlnative.php code that causes all UTF-8 encoded Unicode characters in the database to be double encoded before being sent to the browser, meaning all Unicode characters in posts are instead represented by a series of jibberish characters. The ticket (again with the fix) is here:

https://tracker.phpbb.com/browse/PHPBB3-15847


Some earlier SQL Server bugs that I reported and that have been fixed in later versions:

If you are running 3.0.9 or earlier under PHP 5.x with SQL Server, another instance of the resultset rows issue I mentioned above causes all email notifications to stop being sent: https://tracker.phpbb.com/browse/PHPBB3-10294

If you are attempting to upgrade to 3.2.0 or 3.2.1 under SQL Server, the database upgrade process silently fails with no error, leaving the forum inoperable. Subsequent attempts to upgrade also fail silently. https://tracker.phpbb.com/browse/PHPBB3-15368

Re: MS SQL Server users - here's the latest bug roundup

Posted: Thu Nov 08, 2018 3:26 am
by MarkDHamill
Some of these look familiar. I put this in the tracker more than three years ago:

https://tracker.phpbb.com/browse/PHPBB3-14209

I wonder if they have statistics on how many boards run what kinds of databases. I bet 95%+ are MySQL or MariaDB. Maybe they should just end support for some of these marginal databases.

Re: MS SQL Server users - here's the latest bug roundup

Posted: Thu Nov 08, 2018 3:58 am
by kinerity
gsmaclean wrote:
Wed Oct 17, 2018 2:40 pm
Exception running PHPBB 3.2.x under PHP 7.2.x and SQL Server

PHPBB 3.2.x is supposed to support PHP 7.2.x, however it fails when running under SQL Server because SQL Server result sets under earlier versions of SQL Server don't have Count properties (newer versions can support it, but you must use cursors, which makes queries slow), and the mssqlnative.php code assumes that they all do. The ticket (with the fix) is here:

https://tracker.phpbb.com/browse/PHPBB3-15844
Duplicated by https://tracker.phpbb.com/browse/PHPBB3-15612 and should be fixed in 3.2.4-RC1.