Add debugging info to SQL stacktraces