If this information is unhelpfull, try setting dieonerror (5th param on cFetch and cBuild) to 0.
This will cause the script to not exit() and you can call view the dbseterr and connerr values of the object to
see if there were problems on connection or DB selection.