Fixing object_id while importing Data

Author Message

Mohamed Haimoura

Thursday 04 December 2008 2:50:38 am

Hi,
I'm trying to do an import from 3.9 to 4, and i have many relations between object, so i have to conserve dependencies between object while creating them in the import script.
In my import script i have :

$contentObject = & $class->instantiate();
$contentObject->setAttribute( 'remote_id', $remoteID ) 

i want to know if i can do

$contentObject->setAttribute( 'id', $objetc_id );

In order to attribute a specific (not automatic) value to the object_id.

Thanks

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 16:33:51
Script start
Timing: Jan 18 2025 16:33:51
Module start 'layout'
Timing: Jan 18 2025 16:33:51
Module start 'content'
Timing: Jan 18 2025 16:33:52
Module end 'content'
Timing: Jan 18 2025 16:33:52
Script end

Main resources:

Total runtime0.5748 sec
Peak memory usage4,096.0000 KB
Database Queries46

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0062 588.0156152.6250
Module start 'layout' 0.00620.0038 740.640639.4453
Module start 'content' 0.01000.5630 780.0859401.8125
Module end 'content' 0.57300.0017 1,181.89848.3125
Script end 0.5747  1,190.2109 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00380.6532160.0002
Check MTime0.00150.2583160.0001
Mysql Total
Database connection0.00100.172210.0010
Mysqli_queries0.536593.3359460.0117
Looping result0.00050.0855440.0000
Template Total0.540194.020.2700
Template load0.00230.406920.0012
Template processing0.537793.557220.2689
Template load and register function0.00010.021410.0001
states
state_id_array0.00110.197010.0011
state_identifier_array0.00180.320920.0009
Override
Cache load0.00190.3271110.0002
Sytem overhead
Fetch class attribute can translate value0.00070.120410.0007
Fetch class attribute name0.00050.092010.0005
XML
Image XML parsing0.00010.021110.0001
class_abstraction
Instantiating content class attribute0.00000.000510.0000
General
dbfile0.00110.1845100.0001
String conversion0.00000.002240.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
1content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 9
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs