Medicare billing - Diabetic patients requirements


(Nerik Cavalier) #1

After upgrade to latest Version Number: v5.0.1 (6), we experiencing the problem with medicare claims, submitted with diabetes icd 10 codes.
Rejections -
N253 - Missing/Incomplete/Invalid attending provider primary identifier
N324 - Missing/Incomplete/Invalid last seen/visit day

We had this problem before, but our clearing house Office Ally did mapping for us, and we had no problems for last three years. We just tipped DLS 02/15/2019 in Additional Notes in Miscellaneous Billing Options for HCFA-1500 section, and all sections of claim was field with requested information.

After upgrade, the problem started again, and we contacted Office Ally to help with mapping. But they recommended to try resolve the problem in Open EMR site.

In Miscellaneous Billing Options section , there is box 15, where we can show last seen date by the primary provider, but in box 17 Provider Qualifier, when we selecting referring provider, its not showing in claim and also no chance to select in Box 17 provider selection.
Please let me know how to resolve this problem.


(Stephen Waite) #2

will take a look at what’s screwed up here, openemr/gen_x12_837.inc.php at rel-501 · openemr/openemr · GitHub

looks like this isn’t grabbing the referring providers from the addr book, openemr/date_qualifier_options.php at 5a182187f444c912237b144b4c118ecb3a2c0405 · openemr/openemr · GitHub


(Stephen Waite) #3

try editing the date_qualifier_options.php file, replace the above with

$query = "SELECT id, lname, fname FROM users WHERE npi != '' ORDER BY lname, fname";

this should only grab the users with NPIs


(Nerik Cavalier) #4

Thank you Stephen,

I did changes in my test program ,and I got an error


(Nerik Cavalier) #5

https://community.open-emr.org/t/claims-need-correction-for-office-ally/8593?u=ncavalier

Dear Stephen,
If you can check the link I shared, you can see this is the same problem we try to resolve 2 years ago.


(Stephen Waite) #6

hi, replace the old query entirely with


(Nerik Cavalier) #7

Did twice, page not loading


(Nerik Cavalier) #8

Provider information needs to be taken from demographic form, see attachedScreenshot_2019-03-21%20Test%203


(Stephen Waite) #9

Oh, well you don’t need a code fix then. Sounds like you might need to clear the cache on your browser so it’s not loading the old script.


(Nerik Cavalier) #10

When I changing to old script back, its loads fine again. I did twice, and same problem again.


(Stephen Waite) #11

what browser are you using?


(Nerik Cavalier) #12

I’m using mozilla firefox


(Stephen Waite) #13

restore the script back to it’s original state:

and try clearing the cache in your browser, https://support.mozilla.org/en-US/kb/how-clear-firefox-cache


(Nerik Cavalier) #14

After cleaned cash, did every step again. Same problem.

Copy of my file -

<?php /** * Reusable data entries for new Box 14 and Box 15 date qualifiers that are part of * HCFA 1500 02/12 format * * For details on format refer to: * * * @package OpenEMR * @author Kevin Yeh * @author Stephen Waite * @copyright Copyright (C) 2013 Kevin Yeh and OEMR * @copyright Copyright (C) 2017 Stephen Waite * @link http://www.open-emr.org * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3 */ function generateDateQualifierSelect($name, $options, $obj) { echo ""; for ($idx=0; $idx<count($options); $idx++) { echo "".text($options[$idx][0]).""; } echo ""; } function genProviderSelect($selname, $toptext, $default = 0, $disabled = false) { $query = “SELECT id, lname, fname FROM users WHERE npi != ‘’ ORDER BY lname, fname” . "( authorized = 1 OR info LIKE '%provider%' ) AND username != '' " . "AND active = 1 AND ( info IS NULL OR info NOT LIKE '%Inactive%' ) " . "ORDER BY lname, fname"; $res = sqlStatement($query); echo ""; echo "" . text($toptext); while ($row = sqlFetchArray($res)) { $provid = $row['id']; echo "" . text($row['lname'] . ", " . $row['fname']); } echo "\n"; } $box_14_qualifier_options=array(array(xl("Onset of Current Symptoms or Illness"),"431"), array(xl("Last Menstrual Period"),"484")); $box_15_qualifier_options=array(array(xl("Initial Treatment"),"454"), array(xl("Latest Visit or Consultation"),"304"), array(xl("Acute Manifestation of a Chronic Condition"),"453"), array(xl("Accident"),"439"), array(xl("Last X-ray"),"455"), array(xl("Prescription"),"471"), array(xl("Report Start (Assumed Care Date)"),"090"), array(xl("Report End (Relinquished Care Date)"),"091"), array(xl("First Visit or Consultation"),"444") ); $hcfa_date_quals=array("box_14_date_qual"=>$box_14_qualifier_options,"box_15_date_qual"=>$box_15_qualifier_options); function qual_id_to_description($qual_type, $value) { $options=$GLOBALS['hcfa_date_quals'][$qual_type]; for ($idx=0; $idx<count($options); $idx++) { if ($options[$idx][1]==$value) { return $options[$idx][0]; } } return null; }

(Stephen Waite) #15

try restoring the original file, date_qualifier_options.php (3.2 KB)


(Nerik Cavalier) #16

I restored original file, and everything works fine. But we need to resolve this problem with referring provider selection…


(Stephen Waite) #17

can’t replicate the problem here, https://one.openemr.io/c/openemr/interface/login/login.php?site=default

for phil belford


(Nerik Cavalier) #18

Yes this is actually what we looking for.

Can you please send me updated date_qualifier_options.php file, I will replace its with original one.
I will test it tomorrow in my office

Thank you


(Stephen Waite) #19

it’s the same file that you had originally and then restored, you might have different settings for your providers that could be causing the issue


(Nerik Cavalier) #20

I have checked all 3 EMR systems in our office, and all the same, there is no selection of the doctors in Box17, only current Provider.
Is there is any setting needs to be changed, to generate this process.

The referring provider needs to be assigned automatically, from patient demographics, without selection. If the referring provider selected in patient demographic section, it needs to be shown in Box 17, if the day in box 15 selected.
When Office Ally doing mapping for our claims, if the date last seen assigned, referring doctor name and NPI automatically generating in field 17.