Hello,
Two changes is being made on MediaWiki databases:
First:
We are reworking how extensions manage their database schema. The idea is to basically deprecate LoadExtensionSchemaUpdates hook[1] and replace it with structured values in extension.json.
This is needed to avoid arbitrary php code execution during database update which can cause problems and was a contributing factor in one of our major outages [2]. The other reason for this change is to be able to wire abstract schema of extensions to core so it can be tested in CI (for example for having a valid json, having prefixes set correctly, etc.) You can see a POC of that in [3]
Given that once the change is merged to core, breaking changs to extension registry schema would require a lot of work (updating the maniphest version and so on), it's better to get it right before merge.
Second:
We are working to provide a replacement for raw SQL for query conditions. When the query condition is exact equality condition (e.g. rev_id = 123), you don't need to provide raw SQL but for most other cases you need to either provide it or build it via IDatabase methods. For example: 'rev_timestamp > ' . $db->addQuotes( $db->timestamp( $since ) ). You can see an example of this in [5] (being changed to something much better via a newly introduced method).
This is not optimal and not very developer friendly, to solve that, we are proposing to have something like ExpressionBuilder::greater( 'rev_timestamp', $db->timestamp( $since ) ) supported in SelectQueryBuilder::where().
Thank you