Yes, Paul, that now makes my system crash with Fatal Error too in VFP9 and
VFPA.

On Fri, Nov 22, 2019 at 6:59 AM Paul Newton <paul.new...@pegasus.co.uk>
wrote:

> No Alan - the following code (adapted from Eric) demonstrates exactly what
> I am doing:
>
> #DEFINE _fields 35
> #DEFINE _rows 100
> =RAND(-1)
> CREATE CURSOR crsTest (id i)
> cCalcCmd = [CALCULATE ]
> cInsertFields = []
> cInsertValues = []
> cVariables = []
> FOR x = 1 TO _fields
>    cField = "Field"+TRANSFORM(x)
>    ALTER table crsTest ADD COLUMN (cField) I
>    cCalcCmd = cCalcCmd + "SUM("+cField+"),"
>    cInsertFields = cInsertFields + ","+cField
>    cInsertValues = cInsertValues + ","+TRANS(INT(RAND()*100))
>    cVariables = cVariables + "lc"+cField+","
> NEXT
> cInsertCmd = [INSERT INTO crsTest (ID ] + cInsertFields +[) VALUES
> (0]+cInsertValues+')'
> FOR X = 1 TO _rows
>    &cInsertCmd
> NEXT
> cCalcCmd = Left(cCalcCmd,Len(cCalcCmd)-1) + " To " +
> Left(cVariables,Len(cVariables)-1) &&+ "AVG(Field1)"
> ? cCalcCmd
> &cCalcCmd
> Return
>
> Paul
>
> -----Original Message-----
> From: ProfoxTech <profoxtech-boun...@leafe.com> On Behalf Of Alan Bourke
> Sent: 22 November 2019 12:55
> To: profoxt...@leafe.com
> Subject: Re: Fatal error issuing CALCULATE command
>
> Sent by an external sender
> ------------------------------
>
> Paul
>
> Do you mean you are doing this?
>
> calculate sum(field1 + field2 + ...  + field32) to lnTotal
>
>
>
> --
>   Alan Bourke
>   alanpbourke (at) fastmail (dot) fm
>
[excessive quoting removed by server]

_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: https://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/CAAwxvU=+RCvfxrD=C_+0k8TY52b6YYXzisPNWJ3E8+YgNH=r...@mail.gmail.com
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to