We changed some code from a variable definition and two statements to a single statement, but then the code stopped working.
Did anybody encounter this before? Any idea why this happens? It happens with any DatasetModel.
This works:
method public logical canFindByCustomerNumber(input icCustomerNumber as character):
    define variable CustomerDatasetModel as CustomerDatasetModel no-undo.
    assign CustomerDatasetModel = getByCustomerNumber(icCustomerNumber).
    return CustomerDatasetModel:Customer:Available.
end method.
Changing it like this does not:
method public logical canFindByCustomerNumber(input icCustomerNumber as character):
    return getByCustomerNumber(icCustomerNumber):Customer:Available.
end method.
It raises error 10068:
Lead attributes in a chained-attribute expression (a:b:c)
must be type HANDLE or a user-defined type and valid (not UNKNOWN). (10068)
Stepping with the debugger into the table model's available property reveals that THIS-OBJECT:BufferHandle is valid, but trying to evaluate  BufferHandle:AVAILABLE in the expressions results in "**Not available**".
The following code gives the message below:
message 
     1 valid-object(getByCustomerNumber(icCustomerNumber)) skip 
     2 valid-object(getByCustomerNumber(icCustomerNumber):Customer) skip
     3 getByCustomerNumber(icCustomerNumber):Customer:Available
     view-as alert-box.
1 yes
2 yes
3