On Oct 31, 2017, at 10:26 PM, Cannon Smith wrote:

> This bug was first discovered in July of 2016. See the NUG thread "Does 4D 
> Support Dotted Notation in Object Fields?” if you are interested in how it 
> was discovered (thanks to Douglas Von Roeder). ACI0095526.

I must have missed that iNUG thread.

> Even though I filed the bug report, I can think of at least twice since then 
> that I’ve been bitten by this behavior because I forgot about it. I think 
> this is an example where documenting doesn’t help that much. Thinking 4D will 
> save the changes I’ve made to an object is so natural a thought that I keep 
> forgetting it won’t work in these situations, even though I had documented it 
> myself.

I’ve only done some work with object fields and reviewing the code I see I 
always did work on local object variables. Basically something like this:

OB GET ARRAY([Table]ObjectField;”arrayProperty”;$objectArray_ao)
Manipulate $objectArray_ao
OB SET ARRAY([Table]ObjectField;"arrayProperty";$objectArray_ao)
SAVE RECORD([Table])

If I had not been storing an array of objects in the object field then I would 
have directly reference the object field and currently that does not work. Or 
rather I should say 4D is designed so that it will not work. It is intended to 
not work. So by sheer luck I avoided getting bitten by this bug.  :(

> If it is true that this wasn’t implemented as we naturally think it should 
> have been for performance reasons, I’d like to express that I would prefer it 
> to be slower and know that it is saved than faster and find out later it 
> wasn’t saved.

Amen brother! Cannon is talking sense here. Screw performance! Make an 
exception and don’t optimize. Make the assignment operator “:=“ work as we all 
expect it to work. 

Tim

********************************************
Tim Nevels
Innovative Solutions
785-749-3444
[email protected]
********************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to