>>I have the following SQL SELECT statement:
>>
>>
>> cSQLStatement = "SELECT column1, column2, alltrim(object1.object2.property1) as column3 FROM cursor1 INTO CURSOR cursor2 READWRITE"
>>
>>
>>I execute it by using:
>>
>>
>> &cSQLStatement
>>
>>
>>The problem is that very often for no reason I get an error message "ALIAS object2 is not found". It sometimes works, and sometimes doesn't. Object variable "object1" is declared in the method, it has a member property "object2" properly created, as well as character member property "property1" properly created. If I check the value of object1.object2.property1 before or after the statement, I get a correct value.
>>
>>At the same time, if I create property "property1" as a member of "object1", then this allways works (i.e. the expression would be ...alltrim(object1.object2.property1)...).
>>
>>Real names of columns, properties, cursors and objects references are quite unique in my testing and they are not reserved words, so I could exclude this part.
>>
>>Does anyboby have suggestions on what could be causing this behaviour.
>>
>>The environment is: VFP 9, SP1, W2003 Server, MTDLL.
>>
>>Thanks you!
>>Igor.
>
>this is a bug. VFP don't support object reference into the projection list.
Does not support = bug? For your information, this is the definition of a computer bug:
A computer bug is an error, flaw, mistake, failure, or fault in a computer program that prevents it from working correctly or produces an incorrect result. Bugs arise from mistakes and errors, made by people, in either a program's source code or its design. It is said that there are bugs in all useful computer programs, but well-written programs contain relatively few bugs, and these bugs typically do not prevent the program from performing its task.