byte editor
Posted in 2003
Topics: General Discussion
Warning informix novice... I have a letter head that needs to be updated. The .unl file contains a byte field that needs to be updated. (I need to add a person's name) Does any one know what type of editor to use to edit a byte field in a .unl file? Thanks in Advance, Devin Gibson
Devin Gibson wrote: > Warning informix novice... > I have a letter head that needs to be updated. The .unl file contains > a byte field that needs to be updated. (I need to add a person's name) > Does any one know what type of editor to use to edit a byte field in a > .unl file? The format of a BYTE field in an UNLOAD file (.unl) is hex digit pairs, one pair per character, no new lines anywhere. Consequently, you need an editor that will manage indefinitely long lines and a brain (or editor) that can handle hex <-> character conversions. Alternatively, and more realistically, you should get a program that extracts the BYTE field into a file without the encoding, and then modify the file, and then update it. Actually, there's a document on UNLOAD format in the SQLCMD program source code which is available from the IIUG Software Archive (http://www.iiug.org/software), and the main SQLCMD program also comes with example programs selblob (which unloads a blob - BYTE or TEXT - direct to a file) and updblob (which updates a record with the new value of a blob - BYTE or TEXT again) direct from a file. They're toy programs, but fully working toys. Well, AFAIK they work - they did the last time I checked. Be careful; you can use them to destroy valuable data if you are careless -- sharp tools can hurt when abused. -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/