Focal Point
how to convert a virtual field to real field in focus

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/2381075172

February 14, 2008, 08:33 AM
rb4u
how to convert a virtual field to real field in focus
Hi

this is the defined field from a MFD

MS_CO_NAME/A40 WITH COMPANY = DECODE COMPANY(MSCOMP ELSE '?');

i want to make a change like the below:
company is a real field in MFD that holds the length of A3.

i tried the below code:
COMPANY_A/A4 = EDIT(COMPANY,'9999');
MS_CO_NAME/A40 WITH COMPANY_A = DECODE COMPANY_A(MSCOMP ELSE '?');

i get the error message:

USE REAL FIELD with the WITH clause

can any one help me to solve this error

REVA.


Focus Core 7.1.1 & 7.6.4
XP
MainFrames
February 14, 2008, 08:43 AM
Leah
quote:
COMPANY_A/A4 = EDIT(COMPANY,'9999');
MS_CO_NAME/A40 WITH COMPANY_A = DECODE COMPANY_A(MSCOMP ELSE '?');

i get the error message:

USE REAL FIELD with the WITH clause


Message says it all. In the second define, change COMPANY_A to COMPANY. WITH tells FOCUS when to define the field, you could remove the WITH on the second define as you have COMPANY_A.

Of course, why do you want to define COMPANY_A as A4 for the same decode?


Leah
February 27, 2008, 07:21 AM
rb4u
hi Leah,
Thanks for ur reply


Focus Core 7.1.1 & 7.6.4
XP
MainFrames