xslt transformation through Unix

Hi ..

I have one input XML and I want to convert into another XML using parameter mapping through Database through Unix shell script. But I dont have idea how to do that.

And how can I create xsl sheet if mapping is through database tables.

Please help me on this.

use perl, its better