Remap field as BLOB: {boxes}.body

hswong3i - August 26, 2008 - 16:58
Project:Drupal
Version:7.x-dev
Component:block.module
Category:feature request
Priority:critical
Assigned:hswong3i
Status:needs work
Description

As case mentioned in #147947, this patch remap {boxes}.body as BLOB type.

The code logic should be correct, but it is now buggy for MySQL. It is because of INSERT DELAYED implementation in db_insert() which buggy when call db_last_insert_id() just after it, and MySQL don't support default value for TEXT/BLOB. I will mention the above bugs in other issues.

AttachmentSizeStatusTest resultOperations
boxes-body.patch3.22 KBIdleFailed: Failed to apply patch.View details | Re-test

#1

hswong3i - August 27, 2008 - 18:51
Status:needs work» needs review

Remove the use of db_last_insert_id(), and also merge with http://drupal.org/node/300219 for correct schema definition.

MySQL:

  • update.php: pass (remember to access admin/build/themes and re-click active and default theme after update.php, it should be another bug across D6/7)
  • Insert new custom block: pass, both flash install or after upgrade.
  • Update existing custom block: pass, both flash install or after upgrade.

PostgreSQL:

  • update.php: FAILED. Seems PostgreSQL schema don't handle change field correctly.
  • Insert new custom block: pass, for flash install
  • Update existing custom block: pass, for flash install

AttachmentSizeStatusTest resultOperations
boxes-body.patch4.09 KBIdleFailed: Failed to apply patch.View details | Re-test

#2

hswong3i - September 24, 2008 - 18:01

Revamp with drupal_write_record() for simpler handling.

When combine with simplify drupal_write_record() with db_insert() and db_update(), it can prevent the incorrect input type for pid and uid when compare with using db_insert() directly.

Tested with MySQL and PostgreSQL. Stand alone simpletetest, pass; simpletest when combine with http://drupal.org/node/299088, also pass.

AttachmentSizeStatusTest resultOperations
boxes-body.patch5.09 KBIdleFailed: Failed to apply patch.View details | Re-test

#3

hswong3i - October 8, 2008 - 17:41

Update based on http://drupal.org/node/316095 founding. Revamp BLOB field with nullable.

Tested with MySQL and PostgreSQL. Stand alone simpletest, pass; simpletest when combine with http://drupal.org/node/299088, also pass.

AttachmentSizeStatusTest resultOperations
boxes-body-1223484987.patch3.97 KBIdleFailed: Failed to apply patch.View details | Re-test

#4

Anonymous (not verified) - November 12, 2008 - 10:10
Status:needs review» needs work

The last submitted patch failed testing.

 
 

Drupal is a registered trademark of Dries Buytaert.