Patientnote creation

This forum is for programmers who have questions about the source code.
Post Reply
tpaczesny
Posts: 6
Joined: Fri Nov 02, 2018 9:01 am

Patientnote creation

Post by tpaczesny » Fri Aug 23, 2019 8:52 am

We are working on the application accessing, and possibly modifying information in patientnote table. Our assumption was that entry in this table should exist for every patient. In reality (real dental practice database), it is mainly true, but rarely there happen to be a patient for which patientnote entry is missing completely.

I wonder what triggers creation of this entry? I sometimes saw such entries that are completely empty, so it seems it's not the fact of updating the entry that creates it. Is there any "trigger" that could be reliable to know what this entry has been created?

PatrickC
Posts: 56
Joined: Thu Jun 06, 2019 11:37 am

Re: Patientnote creation

Post by PatrickC » Fri Aug 23, 2019 10:39 am

That is correct that a PatientNote entry is not created when each patient is created. Inserts to the PatientNote table occur when the PatientNotes.Refresh() method is called. This method is called in a number of locations, so there isn't necessarily a specific "trigger" that can be looked for, other than the Refresh method itself. Situations where the Refresh method is called on a Patnum without a PatientNote will result in the empty PatientNote entries you mentioned being created. A patient Merge will also always create a PatientNote entry, if one doesn't already exist, utilizing the Refresh method.
Patrick Carlson
Open Dental Software
http://www.opendental.com

tpaczesny
Posts: 6
Joined: Fri Nov 02, 2018 9:01 am

Re: Patientnote creation

Post by tpaczesny » Fri Aug 23, 2019 12:48 pm

Thank you! This is very helpful.

Post Reply