4 Replies Latest reply: Jul 21, 2016 6:40 PM by Marco Wedel RSS

    Adding a field to a table

    John Simmons

      I have a table. For the sake of example, let's say it's created like so:




      LOAD Myfield1, Myfield2, Myfield3

      RESIDENT SomeOtherTable;


      I wanted to add a sequential record number to the table, so I tried this:le:




      LOAD *, RECNO() as RecordID

      RESIDENT MyTable;


      It added the RecordID field, but it used seemingly random values - 4, 8, 11, 15 instead of the expected 1,2,3,4.


      In order to get the desired result, I had to do this:


      LOAD Myfield1, Myfield2, Myfield3, RECNO() as RecordID

      RESIDENT MyTable;





      I consider this to be a bug (among the many other bugs your product has). Oh wait, the trainer refused to call stuff like this a "bug", preferring instead to call it a "nuance".