How ISNs are assigned?

Hi Team,

I would like to know how ADABAS decides to assign a new ISN or an existing ISN. Also, how it generates (criteria behind it) a new ISN value?

Education, Education, Education. Posting an occasional question is no way to learn a database package (Adabas) or a programming language (Natural).

On a file basis, the DBA assigns one of two “rules”, one of which has two sub rules.

A file either has

  1. User assigned ISN’s

  2. Adabas assigned ISN’s

If 1), a program must supply an ISN when adding a record.

  1. has two sub rules; reusable and non reusable.

If non reusable, ISNs are assigned serially. Thus, load a file with 10,000 records, the ISNs are 1-10,000. Delete 100 records, then add 1 new record, the ISN is 10,001.

If reusable, Adabas checks a table of recently deleted ISNs, if none there, it goes to the Address Converter Table. Thus, load a file with 10,000 records, the ISNs are 1-10,000. Delete 100 records, then add 1 new record, the ISN of the new record will be the same as one of the deleted records.

steve

Hi Steve,

Thanks for that, but the main aim was to understand “the ISN of the new record will be the same as one of the deleted records”.

If 100 records deleted and 1 record added newly what ISN is assigned and how does ADABAS makes a decision to choose a perticular ISN. Is it a sequencial process again starting from ascending order or a random process etc.

Adabas maintains a table of available (previously used) ISNs (and data blocks, too). I haven’t tested this with Adabas 8, but in previous versions, even if ISNs were available for reuse, Adabas might select the next sequential ISN. I don’t know exactly what criteria Adabas uses to determine whether to go to the free ISN table, but I am confident that he makes the right decision based on what is happening at the time.

Back in the days of Adabas 5, I had defined a file to contain a maximum of 1,000 records. A Natural program was used to delete them all. The next time that I attempted to store a record, Adabas reported that the file was full, that is, that no ISNs were available because MAXISN had been reached. Apparently he was attempting to assign ISN 1001 even though ISNs 1 - 1000 were reusable.