ACRA 4.2.3 compatible sql

This SQL works with ACRA 4.2.3.