--
[ ike ] founder - DataFaucet ORM
phone: 781.769.0723
I've been trying to reproduce the problem you described and seem to be
unable to in my environment...
I've got these 2 CFCs
item.cfc
<cfcomponent extends="datafaucet.system.activerecord">
<cfset setTable("tItem") />
</cfcomponent>
And content.cfc
<cfcomponent extends="item">
<cfset addTable(table = "tContent",
column="ItemID", references="ItemID") />
</cfcomponent>
I left these deliberately simple to try and isolate the issue and I made
sure there's no foreign key constraint between the tItem and tContent
tables. The tItem table has an itemName column and the tContent table
has a ContentText column so that I would be certain there was data
coming from both tables.
I'm able to create a content object using
CreateObject("component","content")
I then set the datasource and/or initialize the object and am able to
perform an update() to place data into the table. Once the update has
been performed I've checked to make sure it all got into both tables and
I can see that the getProperties() result shows all the column data
including the newly created primary key
Then I created a new content component to make sure it didn't have any
residual state from the previous object, output the content of
getProperties() to make sure it was empty, then attempted to read that
record in two ways, first via .read(itemid) and next via
init(datasource=ds,objectid=itemid). After both of those methods, the
result of getProperties() shows both the itemName and the ContentText so
it's reading data from both tables
Any more information you could give me would be helpful.
Thanks Sana :)
Not sure why that would be... it uses UUIDs for ID values by default,
and that's what I was using to test with... I'll try this specific ID
value though and see what I come up with.
Okay. You're welcome. :)