Index: trunk/extensions/GeoData/GeoData.sql |
— | — | @@ -33,4 +33,4 @@ |
34 | 34 | |
35 | 35 | CREATE INDEX /*i*/gt_page_id ON /*_*/geo_tags ( gt_page_id ); |
36 | 36 | CREATE INDEX /*i*/gt_id_page_id ON /*_*/geo_tags ( gt_page_id, gt_id ); |
37 | | -CREATE INDEX /*i*/gt_spatial ON /*_*/geo_tags ( gt_lati, gt_loni, gt_lon ); |
| 37 | +CREATE INDEX /*i*/gt_spatial ON /*_*/geo_tags ( gt_lat_int, gt_lon_int, gt_lon ); |
Index: trunk/extensions/GeoData/GeoDataHooks.php |
— | — | @@ -7,10 +7,14 @@ |
8 | 8 | * @param DatabaseUpdater $updater |
9 | 9 | */ |
10 | 10 | public static function onLoadExtensionSchemaUpdates( DatabaseUpdater $updater ) { |
11 | | - if ( $updater->getDB()->getType() != 'mysql' ) { |
12 | | - throw new MWException( 'GeoData extension currently supports only MySQL' ); |
| 11 | + switch ( $updater->getDB()->getType() ) { |
| 12 | + case 'mysql': |
| 13 | + case 'sqlite': |
| 14 | + $updater->addExtensionTable( 'geo_tags', dirname( __FILE__ ) . '/GeoData.sql' ); |
| 15 | + break; |
| 16 | + default: |
| 17 | + throw new MWException( 'GeoData extension currently supports only MySQL and SQLite' ); |
13 | 18 | } |
14 | | - $updater->addExtensionTable( 'geo_tags', dirname( __FILE__ ) . '/GeoData.sql' ); |
15 | 19 | return true; |
16 | 20 | } |
17 | 21 | |