[Isis-users] Help with Cisis - deleting only certain occurrences

Egbert De Smet egbert.desmet at uantwerpen.be
Tue Mar 9 14:14:07 CET 2021


Ernesto,


for your information, this is the solution which I sent to Renate, and she confirmed it works perfectly :

=======

try this proc :

'd301',
(
if iocc > 3 then
'<301>',v301,'</301>'
else
continue
fi
)


That will delete the first 3 occurrences of v301.


In your case you might want to do this only if there are more than 3 occurrences ? Then put the whole proc inside another if :

if nocc(v301) >3 then

   'd301',

   (
    if iocc > 3 then
     '<301>',v301,'</301>'
    else
     continue
    fi
   )
fi



==========

I am currently struggling, apart from health issues (right-hand surgery), with updating EmpWeb. No more transactions are performed when using Java more recent than version 7, even after updating the mysql-connector-java-3.1.12-bin.jar with a more recent one. Is there any way of contacting Barzilai or Ciro about this ?



By the way, how is your health nowadays ? Still able to do some work ? Or just enjoying life there, if not too much affected by corona ?



Egbert de Smet
Universiteit Antwerpen


________________________________
From: isis-users <isis-users-bounces+egbert.desmet=ua.ac.be at iccisis.org> on behalf of spinaker <spinaker at adinet.com.uy>
Sent: Thursday, March 4, 2021 7:46 PM
To: rmorgenstern at iway.na; isis-users at iccisis.org
Subject: Re: [Isis-users] Help with Cisis - deleting only certain occurrences

Dear Renate

The fields are repeatable, so if you remove one occurrence then the remaining ones are automatically renumbered
Due to the re-sequencing, it is not simple to delete several occurrences if they are not consecutive or there are intermediate occurrences
In your case, you want to delete the first three, it is easier

mx snd300 "proc ='d69/1d69/1d69/1" copy = snd301

but this must be analyzed case by case, there are no general rules

regards
ernesto spinak




El 3/3/2021 a las 15:08, Renate Morgenstern escribió:
Hi Ernesto,

I am struggling with mx.
How do I only delete certain occurrences of a tag in a database? I have the following command, but then it deletes ALL the occurrences of tag 301:

mx snd300 "proc=(if v301*0.1='0' then 'd301[1]' fi,)" copy=snd301 now -all

When I add [1] after d301 I get the following error message:

fatal: [1]d301[1]d301[1]

I would like that it deletes occurrences 1-3 only.

Thanks in advance for your help.

Renate

--


Renate Morgenstern
Tel.: +264 61 242124
Cell: +264 81 2910284
Fax: 088637518
10023, Windhoek, Namibia



--
  .^.                                .^.
  ( )                                ( )
  ===                                ===
 =[=]================================[=]=
  | |  Ernesto Spinak                | |
  | |  spinaker at adinet.com.uy<mailto:spinaker at adinet.com.uy>        | |
  | |  Montevideo, Uruguay           | |
  | |  tel/fax  (598) 2622-3352      | |
  | |  celular  (598) 99612238      | |
 =[=]================================[=]=
  ===                                ===
  ( )                                ( )
   V                                  V
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.iccisis.org/pipermail/isis-users/attachments/20210309/00a18cd7/attachment.html>


More information about the isis-users mailing list