(* Collection of code snippets by Arne Vajhøj *)
(* (from articles on eksperten.dk / vajhoej.dk written sometime between 2004 and now) *)
program isqw(input,output);

%include 'isq.inc'

var
   f : file of rec;

begin
   open(f, 'z.isq', new, organization := indexed, access_method := keyed);
   rewrite(f);
   f^.key1 := 1;
   f^.key2 := 'A';
   f^.ival := 123;
   f^.sval := 'This is test #1';
   put(f);
   f^.key1 := 2;
   f^.key2 := 'BB';
   f^.ival := 456;
   f^.sval := 'This is test #2';
   put(f);
   f^.key1 := 3;
   f^.key2 := 'CCC';
   f^.ival := 789;
   f^.sval := 'This is test #3';
   put(f);
   close(f);
end.
