I have some data stored in a CSV file, in this manner:
000000001 @ name @ information @ more information @ some more information
I also have a information.tex file containing the numbers from the first column throughout (this file is \input into my main document):
\chapter{Some information about 000012311}
This is some text about 000012311 and 000012312\footnote{See also 000012313}.
\chapter{Some other information}
This text is about 000000001.
I currently use a BASH script which replaces all numbers appearing information.tex matched to the first column of the CSV file with a macro, \mymacro{}{}{}{}, where each {} contains data from a column (second, third, fourth, and fifth).
For e.g., where the input file above contains This text is about 000000001., using the CSV file line above, it becomes This text is about \mymacro{name}{information}{more information}{some more information}., so when compiled, the text is displayed according to the definition of \mymacro. Essentially, I am using BASH to edit information.tex, after which I compile it.
Can I remove the need for BASH and do this directly with LuaTeX or some form of ConTeXt?
datatool. – Werner Jan 18 '12 at 06:27datatool, but it seems to have difficulty with UTF-8. – Village Jan 18 '12 at 10:21