× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



LOL


Got the instance name as a property and everything is working now.


In the SQL statement, I had to change the fields to include the ID in the as part of the from line in select.

So... it's straight now.

Goofy stuff.


Thanks again!

Jay




On October 18, 2017 at 12:43 PM Jay <tegger@xxxxxxxxxxx> wrote:

Okay.

I got it connecting for the post part.

After running the program in debug I found that it is freaking out on the jdbc_nextRow statement.

at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:271
)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:258)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:376)
at java.net.Socket.connect(Socket.java:546)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorIm
pl.java:60)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAc
cessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:611)
at net.sourceforge.jtds.jdbc.SharedSocket.createSocketForJDBC3(Shared
Socket.java:307)
at net.sourceforge.jtds.jdbc.SharedSocket.<init>(SharedSocket.java:25
7)
at net.sourceforge.jtds.jdbc.ConnectionJDBC2.<init>(ConnectionJDBC2.j
ava:311)
... 1 more

> >
On October 18, 2017 at 12:21 PM Jay <tegger@xxxxxxxxxxx> wrote:

I tried having it use by credentials to see if a network ID is needed. Same results.

> > >
On October 18, 2017 at 12:02 PM Darryl Freinkel <dhfreinkel@xxxxxxxxx> wrote:

On similar issues, I had to get the DBA to create a local user ID not
defined in Active Directory. You may not be allowed to use a network user
ID. Once this was done, I was able to connect.

Darryl.

On Wed, Oct 18, 2017 at 11:06 AM, Justin Taylor <JUSTIN@xxxxxxxxxxxxx>
wrote:

> > > >
> > > > >
I use jTDS on SQL Server 2000 thru 2012, with no change required.

> > > >
I'd start on the SQL Server side. Are they allowing SQL Server
Authentication (I think it's off by default)? Does your user exist on the
new server?

-----Original Message-----
From: Jay [mailto:tegger@xxxxxxxxxxx]
Sent: Wednesday, October 18, 2017 8:59 AM
To: 'RPG programming on the IBM i (AS/400 and iSeries)' <
rpg400-l@xxxxxxxxxxxx>
Subject: iSeries and JTDS

Overnight, our SQL server was upgraded from 2005 to 2012.

Now, routines we had running that read the SQL databases for different
things aren't working as an instance name was added when the new server was
setup.

Now, we get connections refused everywhere.

I moved us to up to jtds 1.3.1 from jtds 1.2.5. No change.

Changed the connection code:

prop = JDBC_Properties();

JDBC_setProp(prop: 'user' : %trim(userStr));

JDBC_setProp(prop: 'password' : %trim(passwordStr));

JDBC_setProp(prop: 'databaseName' : %trim(dbnameStr));

JDBC_setProp(prop: 'instance' : 'MSSQL2012' );

conn = JDBC_ConnProp('net.sourceforge.jtds.jdbc.Driver'

:%trim(connectStr)

: prop );

Connection still refused.

Any ideas?

The connection string itself is jdbc:jtds:sqlserver://JJSQLSRV01:1433

I've tried putting ";instance=MSSQL2012" at the end of it.

Jay

--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD

> > > > >
--

> > > >
> > >
Darryl Freinkel
--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: http://amzn.to/2dEadiD

--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

> >
Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: http://amzn.to/2dEadiD
--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

>
Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: http://amzn.to/2dEadiD


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.