{{tag>category:"OpenInsight Specific"}} [[https://www.revelation.com/|Sign up on the Revelation Software website to have access to the most current content, and to be able to ask questions and get answers from the Revelation community]] ==== Removing dictionary specifications (OpenInsight Specific) ==== === At 12 FEB 1998 04:40:46AM Peter Richards wrote: === I cannot delete 3 dictionary symbolics. They have been saved as lower case (naughty me ) and no matter what I try, I cannot get rid of them. Have tried renaming, changing the symbolic name to uppercase, etc, etc. The %FIELDS% row for the dictionary has these items defined as lowercase, but I cannot change this row (protected). Peter ---- === At 12 FEB 1998 07:37AM Cameron Revelation wrote: === Peter, [i]I cannot delete 3 dictionary symbolics. They have been saved as lower case (naughty me )[/i] No comment on the naught part. ;-) Removing those dictionary items is very easy in BASIC+. The following code should do it (but I haven't tested it): function RemoveLowerCaseKeys(Table) open Table to f else return "Unable to open ": quote(Table) select f eof=0 c=0 loop readnext key else eof=1 until eof test=key convert @lower.case to "" in test if "*":test # "*":key then delete f, key else return "unable to delete ": quote(key) c += 1 end repeat return c: " rows deleted." Run it as follows: run RemoveLowerCaseKeys "DICT." Please make a backup copy of your dictionary and table before running it just in case. Alternatively you could rename the keys to their uppercase equivalents: function RenameLowerCaseKeys(Table) open Table to f else return "Unable to open ": quote(Table) select f eof=0 c=0 loop readnext key else eof=1 until eof new=key convert @lower.case to @upper.case in new if "*":new # "*":key then read rec from f, key else return "unable to read ": quote(key) write rec to f, new else return "unable to write ": quote(new) delete f, key else return "unable to delete ": quote(key) c += 1 end repeat return c: " rows renamed." Cameron Purdy info@revelation.com ---- === At 12 FEB 1998 05:29PM Peter Richards wrote: === Cameron, Thanks for the code, I was tearing my hair out, and becoming quite frustrated because I am rather bald. Peter [[https://www.revelation.com/revweb/oecgi4p.php/O4W_HANDOFF?DESTN=O4W_RUN_FORM&INQID=NONWORKS_READ&SUMMARY=1&KEY=5F288BCDDFE08716852565A900352C1B|View this thread on the forum...]]