|
#1
|
|||
|
|||
![]()
For those interested it is possible via the JExcel Api to use an Excel file as a data source in Mirth.
Last edited by marmanold; 05-25-2011 at 07:15 AM. |
#2
|
|||
|
|||
![]()
That looks pretty easy. I was looking at http://poi.apache.org/spreadsheet/index.html which looks like it can do 2007/2010 xml formats but I never figured out how to use it with Mirth. I need to be able to write Excel files.
I think it would be really nice if we could make that a file connector but I don't know enough about programming to be able to do that and give to the community. |
#3
|
|||
|
|||
![]()
Having Excel as a file destination is definitely possible with this module. I had a small proof of concept somewhere, but I can't find it at the moment. Basically you'd just loop through each row and column of the message writing each data element to the coordinating cell in Excel.
__________________
Michael Arnold| Electronic Data Interchange Specialist PlayMaker CRM Sales Innovation for Home Care A Division of The ADAM Group 115 Southeast Parkway Court | Franklin, TN 37064 866.930.6847 | F: 866.232.6470 | PlayMakerCRM.com |
#4
|
|||
|
|||
![]()
Please bear with me - I'm a Mirth newbie.
What kind of data would you enter in your inbound Excel message template? I'm interested in running some bench tests using sample patient data - lab results, notes, etc. but have no good data source to pass through Mirth. Thx, Lou |
#5
|
|||
|
|||
![]()
The javascript is written to be generic. You can provide it with any Excel (.xls only) file and it will read in all the data on the first worksheet.
You shouldn't put any data in the inbound message template. It is simply the template used for the transformer in your destinations. You will put a <coln></coln> tag for each column used in your Excel report. Because this is read in as an array it's zero-based, so you start counting at zero. (E.g., column one is <col0></col0>, column two is <col1></col1>, etc.) I can tell you that the Java library is a little memory/processor intensive. I was hitting 250MB memory used and 50% processor used while it was processing. I would say it took about five minutes or so to read my 319KB Excel file with about 500 rows.
__________________
Michael Arnold| Electronic Data Interchange Specialist PlayMaker CRM Sales Innovation for Home Care A Division of The ADAM Group 115 Southeast Parkway Court | Franklin, TN 37064 866.930.6847 | F: 866.232.6470 | PlayMakerCRM.com |
#6
|
|||
|
|||
![]()
Hi,
I've tried to follow your instructions, but when I try to use the Channel I reveiced an error saying: Code:
[2011-07-08 09:55:32,817] FATAL (org.mule.impl.DefaultComponentExceptionStrategy:84): The error is: null java.lang.NullPointerException at com.webreach.mirth.connectors.js.JavaScriptMessageReceiver.poll(JavaScriptMessageReceiver.java:88) at org.mule.providers.PollingMessageReceiver.run(PollingMessageReceiver.java:90) at org.mule.impl.work.WorkerContext.run(WorkerContext.java:290) at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650) at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675) at java.lang.Thread.run(Unknown Source) [2011-07-08 09:54:52,754] FATAL (org.mule.impl.DefaultComponentExceptionStrategy:83): The Default Component Exception Strategy has been invoked but there is no current event on the context [2011-07-08 09:51:07,408] ERROR (com.webreach.mirth.connectors.js.JavaScriptMessageReceiver:152): org.mozilla.javascript.EcmaError: TypeError: Cannot call property getWorkbook in object [JavaPackage jxl.Workbook]. It is not a function, it is "object". (62c52ab0-7111-48f0-bafc-db7bccfbb578#9) Thanks, Regards, - Bernd |
![]() |
Tags |
excel, java, jexcel |
Thread Tools | |
Display Modes | |
|
|