Index: kernel/class/edit.php
===================================================================
--- kernel/class/edit.php	(revision 22621)
+++ kernel/class/edit.php	(working copy)
@@ -679,25 +679,57 @@
                 }
                 if ( !$attributeExist )
                 {
-                    if ( $objects == null )
+                    $dataType = $newClassAttribute->attribute( 'data_type' );
+                    if ( $dataType->supportsBatchInitializeObjectAttribute() )
                     {
-                        $objects = eZContentObject::fetchSameClassList( $ClassID );
+                        $db = eZDB::instance();
+
+                        $data = array( 'contentobject_id'         => 'a.contentobject_id',
+                                       'version'                  => 'a.version',
+                                       'contentclassattribute_id' => $newClassAttributeID,
+                                       'data_type_string'         => "'" . $db->escapeString( $newClassAttribute->attribute( 'data_type_string' ) ) . "'",
+                                       'language_code'            => 'a.language_code',
+                                       'language_id'              => 'MAX(a.language_id)' );
+
+                        $datatypeData = $dataType->batchInitializeObjectAttributeData( $newClassAttribute );
+                        $data = array_merge( $data, $datatypeData );
+
+                        $cols = implode( ', ', array_keys( $data ) );
+                        $values = implode( ', ', $data );
+
+                        $sql = "INSERT INTO ezcontentobject_attribute( $cols )
+                        SELECT $values
+                        FROM ezcontentobject_attribute a, ezcontentobject o
+                        WHERE o.id = a.contentobject_id AND
+                              o.contentclass_id=$ClassID
+                        GROUP BY contentobject_id,
+                                 version,
+                                 language_code";
+
+                        $db->query( $sql );
                     }
-                    foreach ( $objects as $object )
+                    else
                     {
-                        $contentobjectID = $object->attribute( 'id' );
-                        $objectVersions = $object->versions();
-                        foreach ( $objectVersions as $objectVersion )
+                        if ( $objects == null )
                         {
-                            $translations = $objectVersion->translations( false );
-                            $version = $objectVersion->attribute( 'version' );
-                            foreach ( $translations as $translation )
+                            $objects = eZContentObject::fetchSameClassList( $ClassID );
+                        }
+                        foreach ( $objects as $object )
+                        {
+                            $contentobjectID = $object->attribute( 'id' );
+                            $objectVersions = $object->versions();
+                            foreach ( $objectVersions as $objectVersion )
                             {
-                                $objectAttribute = eZContentObjectAttribute::create( $newClassAttributeID, $contentobjectID, $version, $translation );
-                                $objectAttribute->setAttribute( 'language_code', $translation );
-                                $objectAttribute->initialize();
-                                $objectAttribute->store();
-                                $objectAttribute->postInitialize();
+                                $translations = $objectVersion->translations( false );
+                                $version = $objectVersion->attribute( 'version' );
+                                foreach ( $translations as $translation )
+                                {
+                                    $objectAttribute = eZContentObjectAttribute::create( $newClassAttributeID, $contentobjectID, $version, $translation );
+                                    $objectAttribute->setAttribute( 'language_code', $translation );
+                                    $objectAttribute->initialize();
+                                    $objectAttribute->store();
+                                    $objectAttribute->postInitialize();
+                                }
                             }
                         }
                     }
Index: kernel/classes/datatypes/ezinteger/ezintegertype.php
===================================================================
--- kernel/classes/datatypes/ezinteger/ezintegertype.php	(revision 22621)
+++ kernel/classes/datatypes/ezinteger/ezintegertype.php	(working copy)
@@ -515,6 +515,25 @@
         $classAttribute->setAttribute( self::INPUT_STATE_FIELD, $minMaxState );
     }
 
+    function batchInitializeObjectAttributeData( $classAttribute )
+    {
+        $default = $classAttribute->attribute( "data_int3" );
+        if ( $default === 0 )
+        {
+            return array();
+        }
+        else
+        {
+            return array( 'data_int'     => $default,
+                          'sort_key_int' => $default );
+        }
+    }
+
+    function supportsBatchInitializeObjectAttribute()
+    {
+        return true;
+    }
+
     /// \privatesection
     /// The integer value validator
     public $IntegerValidator;
Index: kernel/classes/ezdatatype.php
===================================================================
--- kernel/classes/ezdatatype.php	(revision 22621)
+++ kernel/classes/ezdatatype.php	(working copy)
@@ -1391,6 +1391,16 @@
         return true;
     }
 
+    function batchInitializeObjectAttributeData( $classAttribute )
+    {
+        return array();
+    }
+
+    function supportsBatchInitializeObjectAttribute()
+    {
+        return false;
+    }
+
     /// \privatesection
     /// The datatype string ID, used for uniquely identifying a datatype
     public $DataTypeString;
