aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorDavid M <davidmj@users.sourceforge.net>2007-05-23 23:37:04 +0000
committerDavid M <davidmj@users.sourceforge.net>2007-05-23 23:37:04 +0000
commite4de958704bbb4b0a4adbecc3a9360aae5d73ef5 (patch)
tree6bee7b20bffc8bfab9d54b1ba2e2ad42c25af82c /phpBB
parentd180ac3d02d0b3fc6abb79b66cd4b4cc691c1656 (diff)
downloadforums-e4de958704bbb4b0a4adbecc3a9360aae5d73ef5.tar
forums-e4de958704bbb4b0a4adbecc3a9360aae5d73ef5.tar.gz
forums-e4de958704bbb4b0a4adbecc3a9360aae5d73ef5.tar.bz2
forums-e4de958704bbb4b0a4adbecc3a9360aae5d73ef5.tar.xz
forums-e4de958704bbb4b0a4adbecc3a9360aae5d73ef5.zip
- Handle ISO-8859-8-i
- Renamed two indicies for Oracle support #11457 git-svn-id: file:///svn/phpbb/trunk@7669 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/develop/create_schema_files.php4
-rw-r--r--phpBB/includes/utf/utf_tools.php6
-rw-r--r--phpBB/install/database_update.php21
-rw-r--r--phpBB/install/schemas/firebird_schema.sql4
-rw-r--r--phpBB/install/schemas/mssql_schema.sql4
-rw-r--r--phpBB/install/schemas/mysql_40_schema.sql4
-rw-r--r--phpBB/install/schemas/mysql_41_schema.sql4
-rw-r--r--phpBB/install/schemas/oracle_schema.sql4
-rw-r--r--phpBB/install/schemas/postgres_schema.sql4
-rw-r--r--phpBB/install/schemas/sqlite_schema.sql4
10 files changed, 42 insertions, 17 deletions
diff --git a/phpBB/develop/create_schema_files.php b/phpBB/develop/create_schema_files.php
index d3efdc45f2..e89f009242 100644
--- a/phpBB/develop/create_schema_files.php
+++ b/phpBB/develop/create_schema_files.php
@@ -858,7 +858,7 @@ function get_schema_struct()
),
'PRIMARY_KEY' => array('role_id', 'auth_option_id'),
'KEYS' => array(
- 'ath_opt_id' => array('INDEX', 'auth_option_id'),
+ 'ath_op_id' => array('INDEX', 'auth_option_id'),
),
);
@@ -1643,7 +1643,7 @@ function get_schema_struct()
),
'PRIMARY_KEY' => 'image_id',
'KEYS' => array(
- 'i_id' => array('INDEX', 'imageset_id'),
+ 'i_d' => array('INDEX', 'imageset_id'),
),
);
diff --git a/phpBB/includes/utf/utf_tools.php b/phpBB/includes/utf/utf_tools.php
index f6ed6c3ed5..5a3a22d2ac 100644
--- a/phpBB/includes/utf/utf_tools.php
+++ b/phpBB/includes/utf/utf_tools.php
@@ -713,6 +713,12 @@ function utf8_recode($string, $encoding)
{
$encoding = 'cp1252';
}
+ // convert iso-8859-8-i to iso-8859-8
+ else if ($encoding == 'iso-8859-8-i')
+ {
+ $encoding = 'iso-8859-8';
+ $string = strrev($string);
+ }
// First, try iconv()
if (function_exists('iconv'))
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 1f0773eeaf..6002f3e556 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -312,7 +312,26 @@ $unsigned_types = array('UINT', 'UINT:', 'USINT', 'BOOL', 'TIMESTAMP');
// Only an example, but also commented out
$database_update_info = array(
// Changes from 3.0.RC1 to the next version
-// '3.0.RC1' => array(),
+ '3.0.RC1' => array(
+ // Remove the following keys
+ 'drop_keys' => array(
+ STYLES_IMAGESET_DATA_TABLE => array(
+ 'i_id',
+ ),
+ ACL_ROLES_DATA_TABLE => array(
+ 'ath_opt_id',
+ ),
+ ),
+ // Add the following keys
+ 'add_index' => array(
+ STYLES_IMAGESET_DATA_TABLE => array(
+ 'i_d' => array('imageset_id'),
+ ),
+ ACL_ROLES_DATA_TABLE => array(
+ 'ath_opt_id' => array('auth_option_id'),
+ ),
+ ),
+ ),
);
// Determine mapping database type
diff --git a/phpBB/install/schemas/firebird_schema.sql b/phpBB/install/schemas/firebird_schema.sql
index f815449d19..f1c74512eb 100644
--- a/phpBB/install/schemas/firebird_schema.sql
+++ b/phpBB/install/schemas/firebird_schema.sql
@@ -112,7 +112,7 @@ CREATE TABLE phpbb_acl_roles_data (
ALTER TABLE phpbb_acl_roles_data ADD PRIMARY KEY (role_id, auth_option_id);;
-CREATE INDEX phpbb_acl_roles_data_ath_opt_id ON phpbb_acl_roles_data(auth_option_id);;
+CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data(auth_option_id);;
# Table: 'phpbb_acl_users'
CREATE TABLE phpbb_acl_users (
@@ -1176,7 +1176,7 @@ CREATE TABLE phpbb_styles_imageset_data (
ALTER TABLE phpbb_styles_imageset_data ADD PRIMARY KEY (image_id);;
-CREATE INDEX phpbb_styles_imageset_data_i_id ON phpbb_styles_imageset_data(imageset_id);;
+CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data(imageset_id);;
CREATE GENERATOR phpbb_styles_imageset_data_gen;;
SET GENERATOR phpbb_styles_imageset_data_gen TO 0;;
diff --git a/phpBB/install/schemas/mssql_schema.sql b/phpBB/install/schemas/mssql_schema.sql
index 3e58881427..6c2e2ee24d 100644
--- a/phpBB/install/schemas/mssql_schema.sql
+++ b/phpBB/install/schemas/mssql_schema.sql
@@ -141,7 +141,7 @@ ALTER TABLE [phpbb_acl_roles_data] WITH NOCHECK ADD
) ON [PRIMARY]
GO
-CREATE INDEX [ath_opt_id] ON [phpbb_acl_roles_data]([auth_option_id]) ON [PRIMARY]
+CREATE INDEX [ath_op_id] ON [phpbb_acl_roles_data]([auth_option_id]) ON [PRIMARY]
GO
@@ -1392,7 +1392,7 @@ ALTER TABLE [phpbb_styles_imageset_data] WITH NOCHECK ADD
) ON [PRIMARY]
GO
-CREATE INDEX [i_id] ON [phpbb_styles_imageset_data]([imageset_id]) ON [PRIMARY]
+CREATE INDEX [i_d] ON [phpbb_styles_imageset_data]([imageset_id]) ON [PRIMARY]
GO
diff --git a/phpBB/install/schemas/mysql_40_schema.sql b/phpBB/install/schemas/mysql_40_schema.sql
index db814a3613..b0aed4d177 100644
--- a/phpBB/install/schemas/mysql_40_schema.sql
+++ b/phpBB/install/schemas/mysql_40_schema.sql
@@ -72,7 +72,7 @@ CREATE TABLE phpbb_acl_roles_data (
auth_option_id mediumint(8) UNSIGNED DEFAULT '0' NOT NULL,
auth_setting tinyint(2) DEFAULT '0' NOT NULL,
PRIMARY KEY (role_id, auth_option_id),
- KEY ath_opt_id (auth_option_id)
+ KEY ath_op_id (auth_option_id)
);
@@ -788,7 +788,7 @@ CREATE TABLE phpbb_styles_imageset_data (
image_width smallint(4) UNSIGNED DEFAULT '0' NOT NULL,
imageset_id tinyint(4) DEFAULT '0' NOT NULL,
PRIMARY KEY (image_id),
- KEY i_id (imageset_id)
+ KEY i_d (imageset_id)
);
diff --git a/phpBB/install/schemas/mysql_41_schema.sql b/phpBB/install/schemas/mysql_41_schema.sql
index dee258d888..a4eb2519aa 100644
--- a/phpBB/install/schemas/mysql_41_schema.sql
+++ b/phpBB/install/schemas/mysql_41_schema.sql
@@ -72,7 +72,7 @@ CREATE TABLE phpbb_acl_roles_data (
auth_option_id mediumint(8) UNSIGNED DEFAULT '0' NOT NULL,
auth_setting tinyint(2) DEFAULT '0' NOT NULL,
PRIMARY KEY (role_id, auth_option_id),
- KEY ath_opt_id (auth_option_id)
+ KEY ath_op_id (auth_option_id)
) CHARACTER SET `utf8` COLLATE `utf8_bin`;
@@ -788,7 +788,7 @@ CREATE TABLE phpbb_styles_imageset_data (
image_width smallint(4) UNSIGNED DEFAULT '0' NOT NULL,
imageset_id tinyint(4) DEFAULT '0' NOT NULL,
PRIMARY KEY (image_id),
- KEY i_id (imageset_id)
+ KEY i_d (imageset_id)
) CHARACTER SET `utf8` COLLATE `utf8_bin`;
diff --git a/phpBB/install/schemas/oracle_schema.sql b/phpBB/install/schemas/oracle_schema.sql
index 9660dbf386..489c7e7bc5 100644
--- a/phpBB/install/schemas/oracle_schema.sql
+++ b/phpBB/install/schemas/oracle_schema.sql
@@ -187,7 +187,7 @@ CREATE TABLE phpbb_acl_roles_data (
)
/
-CREATE INDEX phpbb_acl_roles_data_ath_opt_id ON phpbb_acl_roles_data (auth_option_id)
+CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data (auth_option_id)
/
/*
@@ -1560,7 +1560,7 @@ CREATE TABLE phpbb_styles_imageset_data (
)
/
-CREATE INDEX phpbb_styles_imageset_data_i_id ON phpbb_styles_imageset_data (imageset_id)
+CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data (imageset_id)
/
CREATE SEQUENCE phpbb_styles_imageset_data_seq
diff --git a/phpBB/install/schemas/postgres_schema.sql b/phpBB/install/schemas/postgres_schema.sql
index c976a2a157..b1ff1d1d11 100644
--- a/phpBB/install/schemas/postgres_schema.sql
+++ b/phpBB/install/schemas/postgres_schema.sql
@@ -169,7 +169,7 @@ CREATE TABLE phpbb_acl_roles_data (
PRIMARY KEY (role_id, auth_option_id)
);
-CREATE INDEX phpbb_acl_roles_data_ath_opt_id ON phpbb_acl_roles_data (auth_option_id);
+CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data (auth_option_id);
/*
Table: 'phpbb_acl_users'
@@ -1039,7 +1039,7 @@ CREATE TABLE phpbb_styles_imageset_data (
PRIMARY KEY (image_id)
);
-CREATE INDEX phpbb_styles_imageset_data_i_id ON phpbb_styles_imageset_data (imageset_id);
+CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data (imageset_id);
/*
Table: 'phpbb_topics'
diff --git a/phpBB/install/schemas/sqlite_schema.sql b/phpBB/install/schemas/sqlite_schema.sql
index 9f48115874..70b4f8de22 100644
--- a/phpBB/install/schemas/sqlite_schema.sql
+++ b/phpBB/install/schemas/sqlite_schema.sql
@@ -73,7 +73,7 @@ CREATE TABLE phpbb_acl_roles_data (
PRIMARY KEY (role_id, auth_option_id)
);
-CREATE INDEX phpbb_acl_roles_data_ath_opt_id ON phpbb_acl_roles_data (auth_option_id);
+CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data (auth_option_id);
# Table: 'phpbb_acl_users'
CREATE TABLE phpbb_acl_users (
@@ -761,7 +761,7 @@ CREATE TABLE phpbb_styles_imageset_data (
imageset_id tinyint(4) NOT NULL DEFAULT '0'
);
-CREATE INDEX phpbb_styles_imageset_data_i_id ON phpbb_styles_imageset_data (imageset_id);
+CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data (imageset_id);
# Table: 'phpbb_topics'
CREATE TABLE phpbb_topics (