<p>I have some short reads aligned using <a href='http://en.wikipedia.org/wiki/BLAT_%28bioinformatics%29'>BLAT</a>, the output is in tabular psl format (including the sequences) for each alignment. Is it possible to convert the blat output to <a href='http://samtools.sourceforge.net/SAM1.pdf'>SAM</a>/BAM format. Myself, I would think it is not because of the lack of some data fields in psl which is required for <a href='http://samtools.sourceforge.net/SAM1.pdf'>SAM</a> format (mainly the CIGAR string), but please proove me wrong! 
Normally I would  advise myself to use a different tool (bwa, bowtie, lastz) and align getting a <a href='http://samtools.sourceforge.net/SAM1.pdf'>SAM</a> file, but what if that wasn't an option (say because you really want to use BLAT or you don't have the input) is there a way to do the conversion. I can possibly code that in perl and share it if someone had an idea how to do it.</p>

(not tested): there is a script named `psl2sam.pl` in:

    samtools/misc/psl2sam.pl
