When I do a select by on a multivalued field, followed by EDIT tablename. The browse list contains the multivalues as keys.
example:
SELECT VOC by F4
EDIT VOC
when I hit F2(browse) or ALT-F, the key list also has the
multivalues it was sorted by.
Is there any way to remove the mulitvalues (besides savelist,
run a program to remove, and then getlist)
BTW - This is version 3.12
How about shelling EDIT thusly:
Create a program called MVEDIT containing the following code:
NEW_COMMAND=@SENTENCE3,999
FILENAME=FIELD(@SENTENCE,' ',2) ;* Or use your favorite parser
OPEN FILENAME TO HANDLE THEN
FINISHED='
LOOP
READNEXT ID, WHICH_VAL ELSE FINISHED=1UNTIL FINISHED
EXECUTE NEW_COMMAND:' ':IDREPEAT
END
Or something like that anyway. To execute, do this:
SELECT whatever
MVEDIT VOC
Wesley..
As usual, Victor has a good programmatic solution. However, I find that doing a select by which is based on a multi-value field can be problematic when doing utility functions like edit. The 'BY' clause causes an explicit exploding of the @MV chain in the table which can be time-consuming and (in the case of a SYMBOLIC) can lead to bizarre errors. My normal strategy is to do a single-value select or select-by (perhaps with filter criteria) and then do an edit. Normally, it shouldn't make any difference what order the records are edited in.
Don Miller
C3 Inc.
I just had another thought. What is the reason for sorting the VOC file by F4? My guess is that you want to view catalogued program pointers. If that is the case, my suggestion would be to create a new VOC dictionary item called, say, PROGRAM_NAME. Define it as a single-valued field. Then select by it instead of F4 to avoid the MV problem.
The VOC was just an example.
I just wanted to find out if I was missing something in the statement
that will keep the MV's out.
.. I guess not …
thanks for the replies