VA FileMan V. 22.0 Programmer Manual Banner


Main Chapter Getting Started Manual Advanced User Manual

Advanced File Definition

OUTPUT Transform

The programmer can write an M OUTPUT transform to convert internal data values to a different external form. Use the variable Y (not X, as used with INPUT transforms).

NOTE: Due to concatenation, do not use IF, FOR or QUIT statements when defining OUTPUT transforms. Also, any variables you introduce within an OUTPUT transform (but not Y) should be NEWed.

To reverse the above example, suppose you wanted always to display the name field with a space character following the comma, even though the space is not stored. You could do something like this:

    OUTPUT TRANSFORM:  S Y=$P(Y,",")_", "_$P(Y,",",2,9) 

In addition to containing M code setting Y, OUTPUT transforms can consist of a computed expression. For example, if you wanted always to display the month and year from a date/time field called FOLLOW-UP, you could write:



Reviewed/Updated: March 10, 2007