Avery 05259 from mySQL
Hey,
I have just purchased a package of Avery 05259 labels and I need to print about 100 unique addresses and 100 identical address (200 total). The addresses are all in a mySQL database in a simple table where I could do select `addresse` from `addresses` where `final`='y'. What is the easiest way to get the addresses from my database to the printer in the proper format for the given labels? Thanks, David |
I'd write a Python script to get the data out of the db. Maybe something like:
Code:
#!/usr/bin/python out columns and get it to come out right (a plain text file). For something fancier though, I'd probably use a pdf library like reportlab ( http://www.reportlab.org/rl_toolkit.html ) to create a pdf on the fly (instead of just printing out the results as plain text). Another option might be to have your script spit out html, then convert that html to a pdf (with some control over how the pdf gets formatted) using htmldoc ( http://www.easysw.com/htmldoc/ ). |
Or you could produce TeX output, then process that into a pdf using tex2pdf.
|
All times are GMT -5. The time now is 11:40 PM. |