Mirth Community

Mirth Community (http://www.mirthcorp.com/community/forums/index.php)
-   Support (http://www.mirthcorp.com/community/forums/forumdisplay.php?f=6)
-   -   Mirth DataWriter does not connect with Oracle 11g (http://www.mirthcorp.com/community/forums/showthread.php?t=216623)

itsjohn 11-01-2016 12:36 PM

Mirth DataWriter does not connect with Oracle 11g
 
Hi All,

Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production
Mirth Connect Server 3.4.2.8129 64bit
Java version: 1.8.0_111

I am unable to connect to an Oracle Database 11g Express. I have installed Oracle Express Edition and the TNSNAMES.ORA contains an entry like this:
XE = XE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = username-txl.city.corp.company.com)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = XE)
)
)

I am using a Database Writer with connection string with the service name in the connection template (Javascript disabled):
jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL= TCP)(HOST=username-txl.city.corp.company.com)(PORT = 1521))(CONNECT_DATA=(SERVICE_NAME=XE)))

When i click on the insert=>get tables i do not get any errors and neither does the table list fetched. Same happens when i use the SID or DB name: xe using connection string:
jdbc:oracle:thin:@username-txl.city.corp.company.com:1521:xe (or XE)

I tested the connection string with a Database Reader (Javascript disabled) and on clicking Select button, it doesnt fetch the tables but if I use a SELECT statement it works. Just wanted to know why the fetching of tables doesn't work.

As part of this question, I also wanted to know if Oracle data types like blob and XMLTypes are supported in Mirth Connect.


Can anyone help me with this issues? Thanks in advance!

appsbyaaron 11-01-2016 12:49 PM

So it IS connecting if you can run a select and get data. Am I missing something??

itsjohn 11-01-2016 12:53 PM

Its connecting but the Mirth does not fetch the tables when I click on Get Tables in the database writer connector.

I also wanted to know if Oracle data types like blob and XMLTypes are supported in Mirth Connect.

appsbyaaron 11-01-2016 12:59 PM

I've been working with MC and databases for 5 years and I don't think I've ever seen the fetching "feature" work. LOL

I'm also pretty sure I've used BLOBS before as well.

itsjohn 11-01-2016 01:00 PM

Thanks! Just tried fetching a BLOB and it worked! Do you know how to insert a XMLType in Mirth Connect?

appsbyaaron 11-01-2016 01:06 PM

Quote:

Originally Posted by itsjohn (Post 257422)
Thanks! Just tried fetching a BLOB and it worked! Do you know how to insert a XMLType in Mirth Connect?

I do not. I've not had to work with that yet.

itsjohn 11-01-2016 01:11 PM

Has anyone used Oracle data type XMLTypes with Mirth Connect? Do they work with inserts? I would appreciate if you give a code snippet for it. Thanks!

appsbyaaron 11-02-2016 07:25 AM

Not my answer. From the new Mirth Connect Slack Channel
http://www.mirthcorp.com/community/f...d.php?t=216581



Quote:


hugosoares

the easy way to do this is just create a statement like:

"insert into table values (xmlType(?))"

and then set the parameter like:

stmt.setString(1, '<xml>Hi there</xml>')

itsjohn 11-02-2016 09:15 AM

Thanks for your reply!

That code doesnt work! The following error is thrown:
DETAILS: JavaException: java.sql.SQLException: ORA-01461: can bind a LONG value only for insert into a LONG column


All times are GMT -8. The time now is 03:44 AM.

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