web stats
Database Writer Syntax - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 07-23-2010, 01:04 PM
iIntegrate iIntegrate is offline
Mirth Newb
Join Date: Jun 2010
Posts: 6
iIntegrate is on a distinguished road
Question Database Writer Syntax

I'm using a File Reader --> Database Writer channel (to Postgres).

It works when I use a hard-coded value like this:

var result = dbConn.executeUpdate("INSERT INTO patient (medicalrecordnumber) VALUES ('12345')");

As expected, it places the value 12345 in the db.

It does NOT work when I do the following:

var result = dbConn.executeUpdate("INSERT INTO patient (medicalrecordnumber) VALUES ($('MedicalRecordNumber'))");

I simply drug over the $('MedicalRecordNumber') from the "Destination Mappings" column on the right side of the screen, after having mapped it in the transformer.

I've tried several different tweaks to the syntax.

Anyone able to offer insight?


- Rod
Rod Sellers
"Psalm 34:3"
Reply With Quote

database writer, postgres, syntax

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -8. The time now is 11:41 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Mirth Corporation