AS400 SQL / DB2

Hi,

Been looking for reference material for the SQL for this system.

Connecting using VB.net app to query. Went to IBM site but pages are no longer available. What’s the best app to query the DB? Used winsql in the past for other work,

Best,

Ross
ross13Asked:
Who is Participating?
 
Gary PattersonVP Technology / Senior Consultant Commented:
IBM i V7R1 and earlier OS versions

If you need to access IBM i DB2 from .NET, the best tool is the IBM i DB2 ADO.NET Provider.  This data connector is part of the IBM i Access for Windows licensed program that is provided by IBM with every system.  You should be able to obtain installation media from your IBM i system administrator.    Same package includes ODBC and OLDdb drivers for IBM i DB2, as well.

https://www-03.ibm.com/systems/power/software/i/access/windows_functions.html

If you have no other way to get media, you can order DVD copies of the last version of IBM i Access for Windows (V7R1) - on the IBM Publications Web site.

Product number: SK3T-4098-05

https://www-05.ibm.com/e-business/linkweb/publications/servlet/pbi.wss

V7R2 and later

IBM i DB2 ADO.NET driver is also an optional component of the newer IBM i Access Client Solution (ACS), which replaces IBM i Access for Windows.

https://www-03.ibm.com/systems/power/software/i/access/solutions.html

You'll need the "IBM i Access Client Solutions - Windows Application Package" optional component to get data drivers.  Instructions are on the IBM web site.  You may need assistance from your IBM i Administrator, IBM Business Partner, or IBM Technical Support to obtain this package, depending on how your relationship with IBM is set up.

SQL Query Tools

One you have the drivers, you can use just about any SQL compatible tool that can use ADO.NET, OLEdb, or ODBC to access IBM i DB2.  I use the "Run SQL Scripts" function in IBM i Navigator, generally, or the green-screen tools STRSQL.  IBM provides a free Eclipse-based cross-platform DB tool called "IBM Data Studio".
1
 
shalomcCTOCommented:
0
 
shalomcCTOCommented:
0
Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

 
MurpheyApplication ConsultantCommented:
Hi Ross13,

This page includes all connectionstrings you can use for the AS/400 (aka iSeries),
https://www.connectionstrings.com/as-400/

I prefer the ODBC version , but they all work flawless.
0
 
Gary PattersonVP Technology / Senior Consultant Commented:
From the IBM Redbook Integrating DB2 Universal Database for iSeries with Microsoft ADO .NET:

http://www.redbooks.ibm.com/redbooks/pdfs/sg246440.pdf

If you are using the .NET framework to connect to an iSeries host, choose the IBM.Data.DB2.iSeries database provider to support your PC and iSeries SQL application development. This managed provider offers better performance than using the System.Data.OleDb provider to bridge to an iSeries Access OLE DB provider, or using the Microsoft.Data.Odbc provider to bridge to the iSeries Access ODBC driver.
0
 
ross13Author Commented:
Thanks for the help guys
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.