JDBC

Syndicate content 12 

The Caché System Management Portal includes a robust web-based SQL query tool, but for some applications it’s more convenient to use a dedicated SQL client installed on a user’s PC.

SQuirreL SQL is a well known open source SQL client built in Java, which uses JDBC to connect to a DBMS. As such, we can configure SQuirreL to connect to Caché using the Caché JDBC driver.

Last comment 13 July 2016
+ 7   0 9
3715

views

+ 7

rating

As we all know, Caché is a great database that accomplishes lots of tasks within itself. However, what do you do when you need to access an external database? One way is to use the Caché SQL Gateway via JDBC. In this article, my goal is to answer the following questions to help you familiarize yourself with the technology and debug some common problems.

Last comment 28 December 2018
+ 8   2 4
2084

views

+ 8

rating

Apache Spark has rapidly become one of the most exciting technologies for big data analytics and machine learning. Spark is a general data processing engine created for use in clustered computing environments. Its heart is the Resilient Distributed Dataset (RDD) which represents a distributed, fault tolerant, collection of data that can be operated on in parallel across the nodes of a cluster. Spark is implemented using a combination of Java and Scala and so comes as a library that can run on any JVM.

+ 11   0 4
1801

views

+ 11

rating

Hi All,

            I have a general query in regards to developers experience on extracting data from cache databases and the most efficient way to do so. I work with a number of clients who have applications with cache databases and require the data off the host system and onto data warehouse platforms for research and analysis. Often they require the data in source state which means the extracts are often simply a table scan of the entire database table without any aggregation or manipulation.

Last answer 26 October 2016 Last comment 26 October 2016
+ 1   0 2
1050

views

+ 1

rating

This is a sample Ensemble/Health Connect production which demonstrates how to receive an HL7 order (ORM) inbound from a file, extract fields (in this case, basic demographic information), and insert those into a table in an external SQL database via ODBC.  

Included in the zip file:

  • Exported code
  • Sample ORM message
  • 'How to configure' doc 
Last comment 19 April 2018
+ 1   0 3
1004

views

+ 1

rating

Hello everyone,

I'm trying to authenticate a user(Health Share clinician) from a Java Application. 

I 'm already connected to Caché and able to run SQL commands.

My question is: How can I authenticate a user using only SQL? In fact, what I want is verify if the users exists in the base and if the given password is the same used in Health Share.

There is a column 'password' in Security.users table but I'm not able to see its content, even so, I don't know which hash function to use to compare with.

Last answer 26 August 2016 Last comment 29 August 2016
+ 1   0 2
844

views

+ 1

rating

I'm referring to the document Using Cache with JDBC. Using this example, it sets the URL of the object ds of class CacheDataSource.

ds.setURL("jdbc:Cache://127.0.0.1:1972/SAMPLES");

My question is would you just copy and paste the URL from the login page to the string? I tried doing that and it returns an error saying "Invalid log file xyz"

 

Any help will be greatly appreciated! Thank you

Last answer 30 December 2017 Last comment 3 January 2018
0   0 1
698

views

0

rating

I have a MySQL server with "posts" table.

I also have a Caché server with "downloadedposts" table. 

They are connected from Caché to MySQL via SQL Gateway

I want to keep Caché table synced with MySQL one  (MySQL "posts" table is a master copy), so periodically Caché queries MySQL server and downloads data. So far so good, and if a record appears or changes in MySQL table, Caché downloads the changes.

The problem I'm encountering is that sometimes rows would be deleted from  MySQL "posts" table.

How do I synchronize deletions?

Last answer 27 June 2016 Last comment 24 June 2016
+ 2   0 1
695

views

+ 2

rating

We are creating a package (written in Caché Object Script) that will provide access to an external DB (MySQL). Because applications that use our package will be run from machines with various, potentially unexpected, operating systems, we’d like to establish a connection to the external DB without using DSNs (we’ve heard that setting up DSNs on certain non-Windows machines can be cumbersome and problematic).

Last answer 1 August 2016 Last comment 26 July 2016
0   0 4
686

views

0

rating

Hi,

I'm developing an integration between Caché servers by ODBC conection, and I have the following problem.

In this call:

call COSClass_Methode('222169^^98^155^64530^06:30^021542987897458855441112877855^1^0^281992^GC')

the ODBC driver is truncating the string to 50 characters.


If I run this same command with $system.SQL.Shell(), this doesn't occur.
I did a test creating several parameters for COSClass_Methode, and they all have a 50 character limitation.

Last answer 6 September 2017 Last comment 7 September 2017
0   1 1
679

views

0

rating

I use DataGrip (JDBC client) to query Caché server via JDBC.

The problem I encountered, is that if I wait 10 or more minutes between queries I get an error:

[08S01][461] Communication link failure: Socket closed

To fix that I need to disconnect and connect to server again. Is there a JDBC timeout setting somewhere I can change?

Last comment 28 December 2016
0   0 2
0

answers

672

views

0

rating

We have a new requirement being push down by our Data Security to no longer use Local SQL Accounts to access our Databases. So they asked me to create a Service Account that is on the Domain for our connections to each database.

I tried just changing my JDBC connection to using this Service Account and Password but I am not having any luck trying to connect to the database.

" Connection failed.
Login failed for user 'osumc\CPD.Intr.Service'. ClientConnectionId:ade97239-c1c8-4ed1-8230-d274edb2e731 "

Last answer 16 August 2018 Last comment 16 August 2018
0   0 3
649

views

0

rating

In MySQL I have the following table:

CREATE TABLE `info` (
   `created` int(11)
);

And it is linked (via JDBC SQL Gateway) to Cache table mysql.info.  `created` field stores unix timestamp. So when I execute  this SQL in SMP:

SELECT created FROM mysql.info

I receive the following output (which is expected):

Last answer 19 May 2016 Last comment 19 May 2016
0   0 0
591

views

0

rating

Astronomers’ tools

5 years ago, on December 19, 2013, the ESA launched an orbital telescope called Gaia. Learn more about the Gaia mission on the official website of the European Space Agency or in the article by Vitaly Egorov (Billion pixels for a billion stars).

However, few people know what technology the agency chose for storing and processing the data collected by Gaia. Two years before the launch, in 2011, the developers were considering a number of candidates (see “Astrostatistics and Data Mining” by Luis Manuel Sarro, Laurent Eyer, William O’Mullane, Joris De Ridder, pp. 111-112):

Comparing the technologies side-by-side produced the following results (source):

TechnologyTime
DB213min55s
PostgreSQL 814min50s
PostgreSQL 96min50s
Hadoop3min37s
Cassandra3min37s
Caché2min25s

The first four will probably sound familiar even to schoolchildren. But what is Caché XEP?

Last comment 9 January 2019
+ 8   1 3
576

views

+ 8

rating

Hi all,

I have a non objectscript application connecting to a cache instance via ODBC and one column is a list of serial objects. The output from the query contains a lot of special characters and I'm hoping there's a better way to get this data back so I won't have to perform extensive parsing on the application side.

I've tried using the $ListToString() function, but that didn't help much, probably because the list contains complex objects rather than primitives. 

Any help will be greatly appreciated!

Last answer 19 June 2017 Last comment 18 June 2017
+ 1   0 3
421

views

+ 1

rating

I need to guarantee that a parent AND child rows has been inserted successfully before any other process is able to read ANY of the data.

What is the proper way to prevent DIRTY reads?  Per the Intersystem's documentation I should be able to use 'START TRANSACTION ISOLATION LEVEL READ COMMITTED'.  I have attempted to use these commands in embedded and dynamic SQL calls to no avail.

Last answer 2 June 2017 Last comment 2 June 2017
0   0 0
416

views

0

rating

I am currently working on a issue with WRC on one of my Inbound SQL Adapters not returning all the records it should be. If I looked at the count of the records in Ensemble and compare it to that of a Microsoft SQL View, Ensemble seems to be off by a few records here and there. I am using a full dynamic select statement in my settings of the adapter.

SELECT Text, PhysicianLastName, PhysicianFirstName, PhysicianAddress1, PhysicianAddress2, PhysicianCity,

Last answer 20 July 2017 Last comment 14 August 2017
0   0 1
399

views

0

rating

Hi, I would like to read a row out of an external SQL table and reference the returned results directly from my cache class. I've set up a  link table and a SQL gateway connection. but I'm not real sure how to use them in COS. Anyone have examples out there, or some assistance? Thank you.

Last answer 31 July 2017 Last comment 1 August 2017
0   0 1
0

comments

396

views

0

rating

I'm new to Iris, trying to follow this guide ( https://community.intersystems.com/post/k-means-clustering-iris-dataset ) about using clustering. I've followed all instructions until showing the data. At that point, `dataFrame.show()` fails with `java.sql.SQLException: Access Denied`.

Last answer 12 September 2018 Last comment 4 October 2018
0   0 1
389

views

0

rating

Hi

 

I created a jdbc connection in the Caché 2010.2.3  with SQLServer 2008R2.

The connection to this DB works correctly. (Conection Sucess)

I try to perform table binding but this connection, even though it is successful, does not load my tables and schemas.

I did the same test on Caché 2015 , with same jar drivers files and works perfectly!

Any idea?

 

Caché 2010.2.3

Red Hat Enterprise Linux Server release 6.2 (Santiago)

java version "1.7.0_09"

 

Caché 2015

Last answer 9 February 2017
0   0 1
0

comments

335

views

0

rating

I get this on some queries in some namespaces.  For instance, this query:

SELECT TOP 10 SessionId, datediff(s,min(TimeCreated),max(TimeCreated)) as ResponseTime
FROM ens.messageheader
GROUP BY SessionId
ORDER BY ResponseTime DESC

It works fine in HSBUS but in HSREG it throws the error.

Server closed communication device

Does anyone know what would cause this? Would it log something more useful somewhere?

Last answer 18 November 2016 Last comment 18 November 2016
0   0 1
325

views

0

rating

I've asked a lot of questions leading up to this, so I wanted to share some of my progress.

The blue line represents the number of messages processed.  The background color represents the average response time.  You can see ticks for each hour (and bigger ticks for each day).   Hovering over any point in the graph will show you the numbers for that period in time.

This is super useful for "at a glance" performance monitoring as well as establishing patterns in our utilization.

Last comment 4 November 2016
+ 5   0 0
300

views

+ 5

rating