Superbill report bug

bradymiller wrote on Wednesday, August 19, 2009:

hey,
Bug in both 3.1.0 and development tip. Get this below billing information:
ERROR: query failed: SELECT billing.*, u.id, u.fname, u.mname, u.lname, CONCAT(u.fname,’ ', u.lname) AS provider_name, u.federaltaxid FROM billing AS b LEFT JOIN users AS u ON ( b.provider_id != 0 AND u.id = b.provider_id ) OR ( b.provider_id = 0 AND u.id = 1 ) WHERE pid=‘1’ AND encounter = ‘2’ AND activity = ‘1’ ORDER BY date
Error: Unknown table ‘billing’

Very odd since the billing table does exist.

Rod, I think this is related to code change you made here:
http://openemr.cvs.sourceforge.net/viewvc/openemr/openemr/library/report.inc?r1=1.6&r2=1.7

-brady

sunsetsystems wrote on Wednesday, August 19, 2009:

This must be due to the “AS b” clause.  I have checked in a fix to report.inc in both branches.  However I’m not able to reproduce the original problem, presumably because of some difference in the MySQL configuration or version.

Rod
www.sunsetsystems.com

bradymiller wrote on Wednesday, August 19, 2009:

cool. It works now.

-brady