... 方互換性のない変更 ¶ The following changes may require you to update your code when you switch from 0.95 to 0.96: 要求される MySQLdb バージョン ¶ (Django が MySQL データベースに接続する際、利用する) MySQLdb Python モジュールの古いバージョンに含まれるバグが ... あるため、 Django で MySQL バックエンドを利用する場合は MySQLdb バージョン 1.2.1p2 以上を要求するようになりました。古いバージョンを利用しようとした場合は例外が発生します。 If you're curr ... ently unable to upgrade your copy of MySQLdb to meet this requirement, a separate, backwards-compatible backend, called "mysql_old", has been added to Django. To use t ... ... 方互換性のない変更 ¶ The following changes may require you to update your code when you switch from 0.95 to 0.96: 要求される MySQLdb バージョン ¶ (Django が MySQL データベースに接続する際、利用する) MySQLdb Python モジュールの古いバージョンに含まれるバグが ... あるため、 Django で MySQL バックエンドを利用する場合は MySQLdb バージョン 1.2.1p2 以上を要求するようになりました。古いバージョンを利用しようとした場合は例外が発生します。 If you're curr ... ently unable to upgrade your copy of MySQLdb to meet this requirement, a separate, backwards-compatible backend, called "mysql_old", has been added to Django. To use t ... ... information in SQLite. When USE_TZ is False , if you attempt to save an aware datetime object, Django raises an exception. MySQLdb -specific exceptions ¶ The MySQL backend historically has raised MySQLdb.OperationalError when a query triggered an except ... ion. We've fixed this bug, and we now raise django.db.DatabaseError instead. If you were testing for MySQLdb.OperationalError , you'll need to update your except clauses. Database connection's thread-locality ¶ DatabaseWrapper obje ... old signed data django.contrib.flatpages Serialization of datetime and time supports_timezone changed to False for SQLite MySQLdb -specific exceptions Database connection's thread-locality COMMENTS_BANNED_USERS_GROUP setting IGNORABLE_404_STARTS and IG ... ... information in SQLite. When USE_TZ is False , if you attempt to save an aware datetime object, Django raises an exception. MySQLdb -specific exceptions ¶ The MySQL backend historically has raised MySQLdb.OperationalError when a query triggered an except ... ion. We've fixed this bug, and we now raise django.db.DatabaseError instead. If you were testing for MySQLdb.OperationalError , you'll need to update your except clauses. Database connection's thread-locality ¶ DatabaseWrapper obje ... old signed data django.contrib.flatpages Serialization of datetime and time supports_timezone changed to False for SQLite MySQLdb -specific exceptions Database connection's thread-locality COMMENTS_BANNED_USERS_GROUP setting IGNORABLE_404_STARTS and IG ... ... n using SeparateDatabaseAndState ( #24278 ). Stripped microseconds from datetime values when using an older version of the MySQLdb DB API driver as it does not support fractional seconds ( #24584 ). Fixed a migration crash when altering ManyToManyField ... ... n using SeparateDatabaseAndState ( #24278 ). Stripped microseconds from datetime values when using an older version of the MySQLdb DB API driver as it does not support fractional seconds ( #24584 ). Fixed a migration crash when altering ManyToManyField ... ... る可能性があります。 MyISAM の主な欠点は、トランザクションをサポートしていないことと、外部キー制約を強制していないことです。 MySQL DB API ドライバ ¶ MySQL には PEP 249 で説明されている Python Database API を実装したドライバがいくつかあります: mysqlclient ... abase = NAME user = USER password = PASSWORD default-character-set = utf8mb4 他にも ssl 、 init_command 、 sql_mode などの MySQLdb connection options が役に立ちます。 sql_mode の設定 ¶ sql_mode オプションのデフォルト値には STRICT_TRANS_TABLES が含まれて ... )に変換します: ALTER TABLE < tablename > ENGINE = INNODB ; これはテーブルの数が多い場合、面倒です。 テーブルを作成する前に MySQLdb の init_command オプションを使用する方法もあります: "OPTIONS" : { "init_command" : "SET default_storage_engine=INNODB" , } ... ... る可能性があります。 MyISAM の主な欠点は、トランザクションをサポートしていないことと、外部キー制約を強制していないことです。 MySQL DB API ドライバ ¶ MySQL には PEP 249 で説明されている Python Database API を実装したドライバがいくつかあります: mysqlclient ... abase = NAME user = USER password = PASSWORD default-character-set = utf8mb4 他にも ssl 、 init_command 、 sql_mode などの MySQLdb connection options が役に立ちます。 sql_mode の設定 ¶ sql_mode オプションのデフォルト値には STRICT_TRANS_TABLES が含まれて ... )に変換します: ALTER TABLE < tablename > ENGINE = INNODB ; これはテーブルの数が多い場合、面倒です。 テーブルを作成する前に MySQLdb の init_command オプションを使用する方法もあります: "OPTIONS" : { "init_command" : "SET default_storage_engine=INNODB" , } ... ... depend on third-party software that hasn't been ported to Python 3 yet, including: the MySQL database backend (depends on MySQLdb) ImageField (depends on PIL) LiveServerTestCase (depends on Selenium WebDriver) Further, Django's more than a web framewor ... ... depend on third-party software that hasn't been ported to Python 3 yet, including: the MySQL database backend (depends on MySQLdb) ImageField (depends on PIL) LiveServerTestCase (depends on Selenium WebDriver) Further, Django's more than a web framewor ... 2026年10月08日