drpwayne wrote on Sunday, December 19, 2010:
Hi,
Can someone clarify to me how to import documents into OpenEMR?
I have several hundred thousand documents - some pdf and some jpg - that are in MySQL. I understand that OpenEMR does not keep documents in the database but in individual files, so I will need to export the documents to individual files. The documents table in OpenEMR is:
id, integer autoincrement
type (enum, “blob”,“web_url”,“file_url”)
size, date, url, mimetype, pages, owner, revision, foreign_id, docdate, list_id
Is “owner” the patient account ('pubid") or the patient id (id?) or the patient pid or none of the above?
What is the foreign_id?
I assume that “size” is optional.
Let’s say I have a pathology report, pdf format, for the patient whose pubid is 30000, and the report is dated 2010-12-01.
I can create a file of any name, say taking the autoincrement id and appending “.pdf” to it, as
\openemr\30000\pathology\101432.pdf
So I put the scan date of the report in “date”, the date of the pathology report in “docdate”, “pdf” in the mimetype, but how is the file associated with patient 30000? Is “30000” put in the foreign_id? Or is it “owner”? Also, do I put a “7” into list_id to show that it is a pathology report?
TIA for any guidance.
- Peter