Seiden Group
Modern Development & Open Source for IBM i
  • Link to LinkedIn
  • Link to Mail
  • Home
  • Seiden PHP+
    • Seiden PHP+
    • Install & Learn
    • SmartSupport
    • PHP Migrations & Upgrades
    • Success Stories
    • Free PHP Assessment
    • Documentation
    • What’s New (Changelog)
  • IBM i Services
    • Development
    • Training & Mentoring
    • Open Source Setup & Upgrades
    • SSL/TLS Install & Learn
    • Performance
  • Support
    • Open Source & PHP
    • VS Code for i
    • Developer Support
    • Support Success Stories
  • VS Code for i
    • Support
    • Training
    • Code for i Resource Guide
    • Getting Started Videos
    • Code for IBM i Fridays
  • Free Stuff
    • IBM i Strategy & Tips
    • PHP Upgrade Assessment
    • CNX Valence Assessment
    • VS Code for IBM i Resources
    • Code for IBM i Fridays
    • QCachegrind Download
    • PHP Toolkit for IBM i Resources
    • Qshell on i Library
  • Blog
  • About
    • About Our Team
    • About Alan Seiden
    • Speakers & Sessions
    • In the News
  • Contact
  • 201.447.2437
  • Search
  • Menu Menu

Seiden Group Blog

Using Yum to Install or Update the IBM i ODBC Driver

July 11, 2022/8 Comments/in ODBC, PHP /by Alan Seiden

ODBC with Db2 for IBM iThe IBM i ODBC driver for Db2 has become easier to install.

Formerly available only as a download requiring several steps, the driver can now be installed and updated on IBM i with Yum or Access Client Solutions (ACS), as easily as with other IBM i open source packages.

Here are instructions for installing the ODBC driver using Yum.

Before you begin

A few prerequisites must be set up before you install the ODBC driver using Yum.

  • IBM i 7.3 or higher
  • Open source environment must be installed
  • If installing via command-line terminal, set the open source PATH

Update certificates, Yum to get new repository

The ODBC driver comes from a new repository named ibmi-release. A one-time update to ca-certificates-mozilla and yum will make this repository available to ACS and Yum.

To update these two packages from a terminal such as SSH or CALL QP2TERM, run this command:

yum update ca-certificates-mozilla yum

or update them individually via ACS Open Source Package Management’s “Updates available” tab:

Yum in Access Client Solutions (ACS)

Yum shown in ACS Installed Packages

Now install or update the ODBC driver

After the updates to ca-certificates-mozilla and yum, the ODBC driver will be available under the name ibm-iaccess.

To install from a terminal, run this command:

yum install ibm-iaccess

To update:

yum update ibm-iaccess

or use ACS. Once installed, the ibm-iaccess package will become visible in the ACS “Installed Packages” window:

ODBC Driver in Access Client Solutions (ACS)

ODBC driver application listed as ibm-iaccess in Installed Packages of ACS

Confirm that ODBC is installed and working

Test your ODBC installation by running the isql command, included with the open source components unixODBC and unixODBC-devel. Make sure these two components are installed using ACS or by running the following command, as before:

yum install unixODBC unixODBC-devel

Now you can test ODBC.

Connect to your IBM i database with the isql command:

/QOpenSys/pkgs/bin/isql -v *LOCAL

You should see a “Connected!” message followed by an SQL prompt:

1
2
3
4
5
6
7
8
9
+---------------------------------------+
| Connected!                            |
|                                       |
| sql-statement                         |
| help [tablename]                      |
| quit                                  |
|                                       |
+---------------------------------------+
SQL>

Type this SQL statement and see the query results below it:

select * from qiws.qcustcdt

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
SQL> select * from qiws.qcustcdt
+---------+---------+-----+--------------+-------+------+--------+-------+-------+---------+---------+
| CUSNUM  | LSTNAM  | INIT| STREET       | CITY  | STATE| ZIPCOD | CDTLMT| CHGCOD| BALDUE  | CDTDUE  |
+---------+---------+-----+--------------+-------+------+--------+-------+-------+---------+---------+
| 938472  | Henning | G K | 4859 Elm Ave | Dallas| TX   | 75217  | 5000  | 3     | 37.00   | 0       |
| 839283  | Jones   | B D | 21B NW 135 St| Clay  | NY   | 13041  | 400   | 1     | 100.00  | 0       |
| 392859  | Vine    | S S | PO Box 79    | Broton| VT   | 5046   | 700   | 1     | 439.00  | 0       |
| 938485  | Johnson | J A | 3 Alpine Way | Helen | GA   | 30545  | 9999  | 2     | 3987.50 | 33.50   |
| 397267  | Tyron   | W E | 13 Myrtle Dr | Hector| NY   | 14841  | 1000  | 1     | 0       | 0       |
| 389572  | Stevens | K L | 208 Snow Pass| Denver| CO   | 80226  | 400   | 1     | 58.75   | 1.50    |
| 846283  | Alison  | J S | 787 Lake Dr  | Isle  | MN   | 56342  | 5000  | 3     | 10.00   | 0       |
| 475938  | Doe     | J W | 59 Archer Rd | Sutter| CA   | 95685  | 700   | 2     | 250.00  | 100.00  |
| 693829  | Thomas  | A N | 3 Dove Circle| Casper| WY   | 82609  | 9999  | 2     | 0       | 0       |
| 593029  | Williams| E D | 485 SE 2 Ave | Dallas| TX   | 75218  | 200   | 1     | 25.00   | 0       |
| 192837  | Lee     | F L | 5963 Oak St  | Hector| NY   | 14841  | 700   | 2     | 489.50  | .50     |
| 583990  | Abraham | M T | 392 Mill St  | Isle  | MN   | 56342  | 9999  | 3     | 500.00  | 0       |
+---------+---------+-----+--------------+-------+------+--------+-------+-------+---------+---------+
SQLRowCount returns -1
12 rows fetched
SQL>

Now exit the isql environment using the quit command:

SQL> quit

Your ODBC installation or upgrade is complete

Use this method to update your ODBC driver as IBM releases new versions, or for hassle-free installation on new IBM i systems. Ever since IBM made ODBC available on their new repository, we have used the Yum installation technique exclusively on all our client systems. It saves a lot of time.

Tags: IBMi, IBMiOSS, odbc, RPM, Yum
Share this entry
  • Share on Facebook
  • Share on X
  • Share on Pinterest
  • Share on LinkedIn
  • Share on Tumblr
  • Share on Reddit
  • Share by Mail
https://www.seidengroup.com/wp-content/uploads/2017/03/SeidenLogo-180.png 0 0 Alan Seiden https://www.seidengroup.com/wp-content/uploads/2017/03/SeidenLogo-180.png Alan Seiden2022-07-11 12:31:092023-02-13 16:26:03Using Yum to Install or Update the IBM i ODBC Driver
Alan Seiden

About Alan Seiden

Alan works to preserve your investment in IBM enterprise systems by designing and implementing modernization strategies that leverage your existing business logic.

With a passion ...Read More

8 replies
  1. ken mcfadden
    ken mcfadden says:
    September 28, 2023 at 8:49 am

    This seems to work. How do you use this to process thru the data returned and do something with it? Like make a csv or something….Moving this out of the shell and into a .py program? Any examples for that?

    Reply
    • Alan Seiden
      Alan Seiden says:
      September 29, 2023 at 12:14 pm

      Ken, I emailed you my slide deck on ODBC, which includes a Python example.

      Reply
  2. Ken Harding
    Ken Harding says:
    July 26, 2022 at 11:40 am

    Hello Alan,

    I updated Yum to the current version using ACS but ibm-iaccess is not in the list to install.
    What do you suggest?

    Thanks,
    Ken

    Reply
    • Alan Seiden
      Alan Seiden says:
      July 26, 2022 at 11:55 am

      Ken, you’re on IBM i 7.3 or higher, right?
      Run
      /qopensys/pkgs/bin/yum repolist
      from SSH, QSH, or CALL QP2TERM
      and look for the repo:
      ibmi-release.
      Do you see ibmi-release?
      You may need to run
      /qopensys/pkgs/bin/yum clean all
      as well.

      Reply
      • Ken Harding
        Ken Harding says:
        July 26, 2022 at 1:54 pm

        Alan, 7.3 TR10. Ran both commands. Do not see ibmi-release. I do see ibm. I get this message when I run /qopensys/pkgs/bin/yum repolist
        [Errno 14] curl#60 – “SSL certificate problem: self signed certificate in certificate chain”. Not sure if that is causing a problem. It does try other mirror and succeed. Do I need to install something else?
        Thanks, Ken

        Reply
    • Alan Seiden
      Alan Seiden says:
      July 27, 2022 at 12:30 pm

      Hi, Ken, we discussed offline and found that you needed to update ca-certificates-mozilla. I’ve added this update in the article text.

      Reply
  3. Jon Paris
    Jon Paris says:
    July 12, 2022 at 10:18 am

    Useful info Alan but with one small problem for me. I had previously used the old System i Access ODBC driver. Although all the instructions provided work as expected – when it comes to exiting SQL I get the error message:

    SQL> exit
    [37000][IBM][System i Access ODBC Driver][DB2 for i5/OS]SQL0199 – Keyword EXIT not expected. Valid tokens: ( CL END GET SET TAG CALL DROP FREE HOLD LOCK OPEN WITH ALTER.
    [ISQL]ERROR: Could not SQLPrepare

    To get out of SQL I have to type “quit”. So why am I connection to the old version? I started SQL with the command you gave (i.e. /QOpenSys/pkgs/bin/isql -v *LOCAL). Perhaps more importantly how do I get rid of the old one.

    Reply
    • Alan Seiden
      Alan Seiden says:
      July 12, 2022 at 11:41 am

      Jon, the exit was a typo on my part. I’ve corrected it to be quit. Thanks for your comment! Glad the instructions were helpful!

      Reply

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

SUBSCRIBE
Open Thinking
Monthly IBM i Strategy & Tips
  • This field is for validation purposes and should be left unchanged.

IBM i Development

  • RPG, COBOL, SQL, Node,
    PHP, Python, Valance, etc.
  • Modernization. Integration.
  • Web and API Solutions
  • Legacy Maintenance
    ...
LET'S GET IT DONE!

Recent Posts

  • Do You Need IBM i Observability?
  • PHP 8.6 is Coming Soon to IBM i
  • Safer npm installation is on the way for Node.js (and all JavaScript)
  • Access Modern Security for IBM i and Connected Web Environments
  • IBM i: A Natural Platform for Agentic AI
  • PHP on IBM i in 2026: The Modernization Engine
  • Your “AS/400” Is a Modern IBM i Platform
  • MCP + AI for IBM i Teams (with a MongoDB example)
  • GnuPG PHP Extension for IBM i: Now Included with Seiden Support
  • Getting Started with Code for IBM i: A Lunch & Learn Video

SEIDEN GROUP: Modern Development & Open Source for IBM i

Home   |   Seiden PHP+   |   IBM i Services  |   Support   |   VS Code for i   |   Free Stuff   |   Blog  |   Privacy Policy  |   Contact         201.447.2437

© 2026 Seiden Group, LLC
  • Link to LinkedIn
  • Link to Mail
Link to: Liam Allan’s Next Adventure Link to: Liam Allan’s Next Adventure Liam Allan’s Next Adventure Link to: What’s in Your ODBC Driver? Link to: What’s in Your ODBC Driver? What’s in Your ODBC Driver?
Scroll to top Scroll to top Scroll to top