|  |     You are right about the behavior.  CAB$ATTRIBUTES gets confused on
    deletes so one must either make multiple or recurring passes. Your
    solution is much smoother, however.   I doubt that there was any patch
    but I am often proven incorrect, of course.
    It's nice to know that this 'feature' has been eliminated in V3.
    Hang in there,
    don
 | 
|  |     I did find a way to remove the repeating attributes from named data:
    
    ;;REMOVE_THEM;;                                          
    
    GET OA$STATUS=1\
    GET #VAL=CAB$ATTRIBUTES.VALUE["TO"]\
    .IF #VAL NES "" THEN CAB DELETE_ATTRIBUTE ,"TO",#VAL\\
       GET #VAL=CAB$ATTRIBUTES.VALUE["TO"]\\
       .IF #VAL EQS "" THEN GET OA$STATUS=0\\
      REPEAT
    
    It's not optimized, but it works.
    
    						Cheers, Dan'l
 | 
|  |     This sounded so familiar that I checked the STARS database and found 
    this article on the old archived ALL-IN-1 database.  Since it sounds
    like the problem still exists in V2.4 I will move it into the
    current production database.  Maybe this will help.  I'm glad to here
    that it is not a problem n V3.0.
    
    Happy coding,
    
    Faith Donohue
    
    
Problem With CABINET DELETE_ATTRIBUTE
********************   CAUTION:  FOR INTERNAL USE ONLY   *********************
*                                                                            *
*      THIS INFORMATION IS FOR USE BY DIGITAL EQUIPMENT CORP. AND ITS        *
*      EMPLOYEES ONLY.  PLEASE USE EXTREME CARE IF YOU MUST DISCUSS ANY      *
*      PART OF THIS INFORMATION WITH ANYONE WHO IS NOT A DIGITAL EMPLOYEE.   *
*                                                                            *
******************************************************************************
PRODUCT: ALL-IN-1 V2.2
SOURCE: Customer Support Center/Atlanta USA
\by Faith Donohue
\
PROBLEM:
The ALL-IN-1 function CABINET DELETE_ATTRIBUTE moves the attribute
pointer to the SECOND attribute following the one deleted rather than
to the next attribute as it should.  Here's the deal: 
        1. Create a mail message with addressees in the following format:
           
           user1                        ( user@a1@node )
           user2                        ( PAPER MAIL )
           user3                        ( PAPER MAIL )
           user4                        ( user@a1@node )
        2. Run a script containing the following:
           FOR CAB$ATTRIBUTES:"TO" WITH .VALUE <=> "PAPER MAIL" - 
           DO CABINET DELETE_ATTRIBUTE ,"TO",.VALUE
                                                     
        3. You would expect your mail message to have NO paper mail 
           recipients but, in reality, the addressee list is: 
           user1                        ( user@a1@node )
           user3                        ( PAPER MAIL )
           user4                        ( user@a1@node )
                                  
           If the PAPER MAIL addressees are separated by at least one 
           other type of address, this problem does not occur.
                 
SOLUTION:
The problem that you have described is not currently scheduled for
correction in the next release of ALL-IN-1, however, we are able to
supply an alternative. The problem is being considered for resolution in
a future release of ALL-IN-1 following the next release. 
The problem is caused by the deletion of an attribute not moving the
FOR loop pointer backwards resulting in some attributes not being
examined. 
There are two possible alternatives: 
        Firstly, set the attribute to a null string instead of 
        deleting it.  To do this use CAB CHANGE_ATTRIBUTE instead 
        of CAB DELETE_ATTRIBUTE. 
        Alternatively, repeat the FOR loop until no changes to 
        attributes are made.  The script below shows how to 
        achieve this:
        .label do_again   
        compute #count = 0       
        for cab$attributes:"to" with .value <=> "PAPER MAIL" - 
        do cabinet delete_attribute ,"to",.value \\ compute #count = #count+1
        .if #count gt 0 then .goto do_again                                 
\\%QX902 VER_2.2_A1_IOS
\\OAOLD OA A1_IOS
    
    
 |