_ [システム運用] xlhtml が巨大な HTML テーブルを吐く http://www.city.yokohama.jp/me/kenkou/iso/19data/kf-01.xls を xlhtml にかけると、248桁8451行、34MB の素敵な HTML テーブルが吐き出される。 なぜそんな Excel ファイルを作ってしまいますか…。 xlhtml のオプション -te (Trims empty rows & columns at the edges of a worksheet) をつければ改善されるかと思いきや変わらず。 仕方ないので | perl -pe 's"<TD[^>]*>( )*</TD>\n""g' | grep -v '<TR></TR>' なフィルタを通すと、34MB あった HTML は 16KB に縮んだ。(どんだけ空セル含んでたんだよ)
![xlhtml が巨大な HTML テーブルを吐く - [ぴ](2007-05-01)](https://cdn-ak-scissors.b.st-hatena.com/image/square/d228e8be070c32c738781e15c25aeb18f4dc6807/height=288;version=1;width=512/https%3A%2F%2Fpmakino.jp%2Ftdiary%2Ftheme%2Fogimage.png)