Adding catch around cfheader
Fixing sql issue