Sunday, November 22, 2026

How to integrate oracle SQL-cL MCP server using VS code

Ø  Introduction

Model Context Protocol (MCP) has emerged as a popular standard for enabling communication between AI agents and external tools or data sources. Before MCP, developers had to create custom integrations for each data source, which often increased development effort and made applications harder to maintain. MCP simplifies this process by providing a standardized interface between AI applications and external systems. In an MCP-based architecture, the AI agent primarily acts as an orchestrator, while the actual interactions with databases, APIs, and other resources are performed by MCP servers.

This article provides a brief overview of MCP architecture and demonstrates a practical use case with an Oracle Database using the Oracle SQL Developer extension in Visual Studio Code.

Why is MCP important for Oracle professionals?

Traditionally, developers needed to manually write SQL queries, database integrations, and API connectivity layers. MCP enables AI agents to discover and interact with Oracle databases through standardized tools. This reduces integration complexity and allows AI-driven workflows such as schema exploration, query generation, database health analysis, and data discovery.

 

Ø  MCP architecture

MCP (Model Context Protocol) is an open-source standard for connecting AI applications to external systems. Using MCP, AI applications like Claude or ChatGPT can connect to data sources (e.g. local files, databases), tools (e.g. search engines, calculators) and workflows (e.g. specialized prompts)—enabling them to access key information and perform tasks.

 



MCP follows a client-server architecture where an MCP host — an AI application like Claude Code or Claude Desktop — establishes connections to one or more MCP servers. The MCP host accomplishes this by creating one MCP client for each MCP server. Each MCP client maintains a dedicated connection with its corresponding MCP server.Local MCP servers that use the STDIO transport typically serve a single MCP client, whereas remote MCP servers that use the Streamable HTTP transport will typically serve many MCP clients.The key participants in the MCP architecture are:

MCP Host: The AI application that coordinates and manages one or multiple MCP clients

MCP Client: A component that maintains a connection to an MCP server and obtains context from an MCP server for the MCP host to use

MCP Server: A program that provides context to MCP clients

For example: Visual Studio Code acts as an MCP host. When Visual Studio Code establishes a connection to an MCP server, such as the SQL cl MCP server the Visual Studio Code runtime instantiates an MCP client object that maintains the connection to the SQL cl MCP server.

Note that MCP server refers to the program that serves context data, regardless of where it runs. MCP servers can execute locally or remotely. For example, when Claude Desktop launches the filesystem server, the server runs locally on the same machine because it uses the STDIO transport. This is commonly referred to as a “local” MCP server. The official Sentry MCP server runs on the Sentry platform, and uses the Streamable HTTP transport. This is commonly referred to as a “remote” MCP server.

 

MCP consists of two layers:

Data layer: Defines the JSON-RPC based protocol for client-server communication, including capability and version discovery, and core primitives, such as tools, resources, prompts and notifications.

Transport layer: Defines the communication mechanisms and channels that enable data exchange between clients and servers, including transport-specific connection establishment, message framing, and authorization.

How This Works in AI Applications

When the language model decides to use a tool during a conversation, the AI application intercepts the tool call, routes it to the appropriate MCP server, executes it, and returns the results back to the LLM as part of the conversation flow. This enables the LLM to access real-time data and perform actions in the external world.

 

Ø  Environment/Tools used:

A.              Download and install vss code using below link

https://code.visualstudio.com/download

B.              Install latest Oracle SQL Developer for VSCode extension

C.              Install Cline extension

D.              Create an autonomous database in OCI

E.               Download sample schema from oracle using below GIT repository link and import the data

https://github.com/oracle-samples/db-sample-schemas/releases/tag/v23.3

Import Data with Oracle Data Pump Latest Version or an Older Version

 

Ø  Pre-requisite:

Test successful database connection from SQL developer to your ADB instance.

 

Ref:- https://docs.oracle.com/en/database/oracle/sql-developer/23.1/dmrig/download-client-credentials-wallet-files.html

Select your ADB instance from OCI console and click on database connection tab.There you can see

Download wallet button.




 

Please provide password and download the wallet in your local desktop/laptop where SQL developer is running. Make sure you save or remember the password you have used.

 



 

Click on the SQLdeveloper tools as shown in left panel and provide connection information.

You need to select connection type as Cloud Wallet. 



If you forgot admin password then it can be changed from More actions tab(Administrator password) in OCI console and change password



 Setup cline which is an open source AI coding agent using below options




 

Select Free model like below.If you have subscription for Claude you can utilize that one also.Click on create my account and it will take you

to use your email account and complete your authentication to cline.                       

     


                                     

Add MCP server provided by SQL developer extension

Click on Cline tool from the left panel and hover over 3 parallel bars as highlighted below and click on settings button

 


    Click on edit configuration



               Find the absolute path of sqldev.exe and add below line

                              {

        "mcpServers": {

        "SQLcl - SQL Developer": {

        "timeout": 60,

        "type": "stdio",

        "command": "C:\\Users\\DELL\\.vscode\\extensions\\oracle.sql-developer-26.3.1-win32-x64\\cli\\sqldev.exe",

        "args": [

        "--jvm-option",

        "-Duser.language=en",

        "sql",

        "-mcp"

                 ]

               }

             }

 }

                You can see connection has been established and green dot is appeared like below




What happens behind the scenes?

1.      Cline starts sqldev.exe sql -mcp

2.      SQL Developer registers MCP tools

3.      Cline discovers available tools

4.      LLM decides which tool to invoke

5.      Tool executes SQL against Oracle Database

6.        Result is returned to the user

 

Current limitations:

Ø  Access is restricted by database privileges.

Ø  Incorrect AI-generated queries may still need validation.

Ø  MCP does not replace DBA knowledge.

Ø  Sensitive production databases should be protected with proper access controls.


After the MCP server is configured successfully, we can begin interacting with the Oracle database using natural language prompts.

Below is an user query where I asked size of the database..

 




 Help me to write a query which product has highest sale group by country..



I hope you have learned something useful..

Tuesday, November 10, 2026

Foundational knowledge for EBS patching

 

Executive Summary: Oracle EBS patching has many steps which can not be covered in one single MOS article.This document  will guide how to create a document to apply all pre-requisite patches and EBS CSPU patch which is published every month by Oracle.Each steps have been described with all necessary details providing output so that reader can easily understand.

Oracle announcement: Beginning May 28, 2026, Oracle will deliver a Critical Security Patch Update (CSPU) each month. CSPUs provide targeted fixes for critical vulnerabilities in a smaller, more focused format, allowing customers to address high-priority issues without waiting for the next quarterly release.

CSPUs complement Oracle’s existing quarterly Critical Patch Updates (CPUs):

  • Monthly CSPUs deliver timely, high-priority fixes for critical issues
  • Quarterly CPUs remain cumulative, including all fixes released in prior CSPUs

Reference:- Update: Monthly Critical Security Patch Updates (CSPUs) Begin May 28, 2026 | security

Base MOS article:We need a base MOS article from where we will navigate through many different articles.Please follow below MOS article as starting point

Identifying the Latest Monthly and Quarterly Critical Patch Updates for Oracle E-Business Suite Release 12.2

KA923

At any given point of time it will list out only latest 2 CSPU patches.Below is an example.If we really want to apply patches older than what this note says then we have to refer patch document specific for that month.

Latest Patch Update

Patch Update Type

Patch Update Details and Application Instructions

October 2026

CPU

KA1818, Oracle E-Business Suite Release 12.2 Critical Patch Update Availability Document (October 2026)

September 2026

CSPU

KA1806, Oracle E-Business Suite Release 12.2 Critical Security Patch Update Availability Document (September 2026)

 

Build the foundation: Before we jump into going through the document we should first understand what are the different types of patches we need to apply in EBS and which oracle homes are associated with those patches.

Patch type

Examples

Applied with

Home or location it updates

Database technology stack patches

Database RU, OJVM, DBBP, datapatch, ETCC-required DB fixes

OPatch, then datapatch

The Database ORACLE_HOME (RDBMS home). If you use ASM or GI, as on ODA, the Grid home is patched separately.

Fusion Middleware patches

WebLogic PSU and overlays, FMW Web Tier, oracle_common

OPatch

The FMW_HOME on the application tier. Its sub-homes are typically wlserver_10.3, webtier and oracle_common.

Forms and Reports patches

OracleAS 10.1.2 patches

OPatch

The OracleAS 10.1.2 ORACLE_HOME (Forms and Reports) on the application

AD / TXK patches

AD and TXK delta RUPs, the codelevels tracked in AD_TRACKABLE_ENTITIES

adop, usually with the special steps in the readme

The same APPL_TOP location, because they patch the tools that run adop itself.

EBS application patches

One-off bug fixes, merged patches (AD Merge), consolidated patches, bundle patches, RUPs, and the EBS CPU patch (for example 12.2.0 : CPU PATCH FOR …)

adop (online patching)

The APPL_TOP / COMN_TOP of the patch file system (fs1 or fs2), and the editioned database objects in the patch edition.

 

Except Database Technology stack patches rest of the patches may be overwhelming for core DBA's who are transitioning to APPS DBA or interested to learn. Now we will learn about different Oracle homes and corresponding software stack.

Oracle Fusion Middleware ORACLE_HOME (the left box)

This home runs the main EBS services. WebLogic Server and Oracle HTTP Server both live here. The boxes inside it are:

Component

What it does

HTTP Server (Apache)

This is Oracle HTTP Server, the web entry point. It receives browser requests and forwards them to the right WebLogic managed server.

WLS-forms

The WebLogic managed server that handles Oracle Forms requests. It starts Forms sessions.

WLS-oacore

The managed server that runs the OA Framework pages, such as self-service and HTML-based screens.

WLS-oafm

The managed server for web services and related services, such as the Integrated SOA Gateway.

 

 

OracleAS 10.1.2 ORACLE_HOME (the right box)

This is the older Forms and Reports tools home. Oracle still uses it because the EBS forms are built with Forms 10g. It holds two things:

  • formsapp.ear: the Forms application package. Oracle says the EBS Forms modules are deployed out of this home.
  • frmweb: the Forms runtime executable. It starts for each user's Forms session.

What the arrows mean

  • Dashed arrows between WLS-forms and the 10.1.2 home: these two interact at run time. The Forms managed server in the FMW home uses the Forms application and the frmweb executable from the 10.1.2 home. When a user opens a form, WLS-forms starts frmweb from the 10.1.2 home.
  • Solid lines from WLS-oacore and WLS-oafm to COMMON_TOP: these two servers load the EBS Java classes and other files from COMMON_TOP. COMMON_TOP is part of the EBS file system (fs1 or fs2), not an Oracle home.

So in a nutshell we learned about 2 U01

·       OracleAS 10.1.2 ORACLE_HOME (Forms and Reports) on the application where we apply patches under forms and reports

·       The FMW_HOME where we apply patches in Weblogic software home,oracle_common and web tier

Next is AD and TXK patches.What are these patches and why do we need to apply these patches.

AD stands for Applications DBA. This module is the management core of EBS.

  • What it does: It provides all the command-line utilities, software installers, and patch-application engines used by DBAs.

TXK stands for Technology Stack. This module manages the integration between the EBS product files and the middle-tier software components.

  • What it does: It handles the complex scripts and configuration templates that tie EBS to Oracle WebLogic Server, Oracle HTTP Server, and the Oracle Database.

How they are structured inside APPL_TOP

When we apply these patches, files are written directly into their respective module directories under APPL_TOP:

  • $AD_TOP (e.g., <BASE_DIRECTORY>/fs1/EBSapps/appl/ad) — Stores the source files for adop, adadmin, and driver scripts.
  • $TXK_TOP (e.g., <BASE_DIRECTORY>/fs1/EBSapps/appl/txk) — Stores AutoConfig automation files and middleware deployment configuration templates.

Now the most important EBS application patches which are applied in below fashion

  • If your users are currently active on fs1 (the Run File System), adop will automatically identify fs2 as the Patch File System.
  • It writes all file updates (.txt, .jsp, .wfx, forms, reports, etc.) to the APPL_TOP and COMN_TOP directories inside that Patch File System.

Hope we have now built the foundational concepts before we dive into patch notes.

Tools and accelerators :Oracle provides various scripts to find patches required to apply to make our EBS environment to desired CSPU level

Please download below patches and extract zip file to find various scripts

17537119: EBS 12.2 TECHNOLOGY CODELEVEL CHECKER (ETCC)

37171025 to run Java Critical Patch Update Checker (EJCPUC)

35583866 to run Critical Patch Update Checker (ECPUC)

Ø  Patch 17537119: After extraction we can see checkDBpatch.sh and checkMTpatch.sh.

Login into database server and set oracle database environment for pluggable DB.Execute checkDBpatch.sh like below

cd $ORACLE_HOME/appsutil/etcc

 

./checkDBpatch.sh contextfile=$ORACLE_HOME/appsutil/"${ORACLE_PDB_SID}"_`hostname`.xml

 

This will find missing/recommended DB patches like below

+---------------------------------------------------------------------------------------+

[WARNING] 39472050 - DATABASE RELEASE UPDATE 19.32.0.0.260721 is not applied.

This is the recommended database Release Update. You should install it now

and then rerun this script to check for any further fixes available.

 

    - Filename: p39472050_190000_SOLARIS64.zip

 

+---------------------------------------------------------------------------------------+

 

Now we shall execute checkMTpatch.sh file inside DB home as used in previous step but using APPS tier context file

./checkMTpatch.sh contextfile=$CONTEXT_FILE

 

Bugfix XML file version: 120.0.12020000.69

This file will be used for identifying missing bugfixes.

 

Mapping XML file version: 120.0.12020000.57

This file will be used for mapping bugfixes to patches.

 

 

[WARNING] ETCC: Bugfix XML file (./mw/txk_R1220_MT_base_bugs.xml) is more than

 30 days old.

 

Checking for prerequisite bugfixes in file edition: run

 

Enter the password for the APPS user:

Connecting to database.

Database connection successful.

The installed AD.C.14 codelevel supports storing the results in the database.

Checking for existence of ETCC results table.

Table to store results already exists in database.

 

===============================================================================

Oracle Forms and Reports

===============================================================================

Now examining Oracle Forms and Reports.

 

Oracle Home: /u01/ebsdev/R122/fs1/EBSapps/10.1.2.

Product version: 10.1.2.3.0.

Checking required bugfixes for Oracle Forms and Reports 10.1.2.3.0.

All required bugfixes are present for Oracle Forms and Reports.—-No action required for forms and report patches

These results have been stored in the database.

 

Identified DST version: 18

 

Checking required bugfixes for RSF 10.1.0.5.0 in Oracle Forms.

All required bugfixes are present for RSF 10.1.0.5.0 in Oracle Forms.

These results have been stored in the database.

 

===============================================================================

Oracle Fusion Middleware (FMW) - Web Tier

===============================================================================

Now examining Oracle Fusion Middleware (FMW) - Web Tier.

 

Oracle Home: /u01/ebsdev/R122/fs1/FMW_Home/webtier.

Product version: 11.1.1.9.0.

Checking required bugfixes for FMW - Web Tier 11.1.1.9.0.

  Missing Bugfix: 31909295  -> Patch 32287205

  Missing Bugfix: 31748000  -> Patch 32287205

  Missing Bugfix: 31696577  -> Patch 32287205

  Missing Bugfix: 27072923  -> Patch 32287205

  Missing Bugfix: 31169366  -> Patch 32287205

  Missing Bugfix: 17428816  -> Patch 32287205

  Missing Bugfix: 31658943  -> Patch 32287205

  Missing Bugfix: 34067016  -> Patch 34067016

--So it is recommended to apply above highlighted patches

The above list shows missing bugfixes for FMW - Web Tier.

These results have been stored in the database.

 

Identified DST version: 18

 

Checking required bugfixes for RSF 11.1.0.7.0 in FMW Web tier.

All required bugfixes are present for RSF 11.1.0.7.0 in FMW Web tier.

These results have been stored in the database.

 

===============================================================================

Oracle Fusion Middleware (FMW) - Oracle Common

===============================================================================

Now examining Oracle Fusion Middleware (FMW) - Oracle Common.

 

Oracle Home: /u01/ebsdev/R122/fs1/FMW_Home/oracle_common.

Product version: 11.1.1.9.0.

Checking required bugfixes for FMW - Oracle Common 11.1.1.9.0.

All required bugfixes are present for FMW - Oracle Common.—No actioen required for oracle_common under FMW_HOME

These results have been stored in the database.

 

===============================================================================

Oracle WebLogic Server (WLS)

===============================================================================

Now examining WLS.

 

Oracle Home: /u01/ebsdev/R122/fs1/FMW_Home/wlserver_10.3.

Product version: 10.3.6.0.231017.

Note: For WLS, patches rather than bugfixes are verified.

Checking required patches for WLS 10.3.6.0.231017.

All required patches are present for WLS.

These results have been stored in the database.

 

===============================================================================

 

Generating Patch Recommendation Summary.

 

===============================================================================

PATCH RECOMMENDATION SUMMARY

===============================================================================

One or more products have bugfixes missing.

The default patch recommendations to install these missing bugfixes are:

 

-------------------------------------------------------------------------------

Oracle Fusion Middleware (FMW) - Web Tier 11.1.1.9.0

-------------------------------------------------------------------------------

  Patch 32287205 [IMPORTANT: Follow Note 2555355.1 before applying.]

    - Filename: p32287205_111190_SOLARIS64.zip

 

  Patch 34067016

    - Filename: p34067016_11119210420OSS_SOLARIS64.zip

 

Apply the required patches and rerun this script.

 

+-----------------------------------------------------------------------------+

A consolidated zip file with the required application tier patches is

available on My Oracle Support via:

 

  Patch 39034731

    - EBS RELEASE 12.2 CONSOLIDATED FMW FIXES FOR JUL 2026

 

+-----------------------------------------------------------------------------+

 

See My Oracle Support article KA988 for any special instructions regarding these patches.

Footnotes in My Oracle Support article KA988 also apply to corresponding overlay patches.

 

 

===============================================================================

[WARNING] Patch 38073442 (WLS PSU 10.3.6.0.250715) is not installed.

 

Oracle strongly recommends installing this WLS PSU from My Oracle Support

(see article KA988). WLS PSUs are not included in the consolidated ZIP file.

 

After installation, rerun this script to check for additional fixes.

+-----------------------------------------------------------------------------+

Finished checking prerequisite patches for file edition: run.

Thu Oct 22 10:15:17 MST 2026

 

Ø  Patch 37171025:After extraction we can see ejcpuc.sh file.We need to run this script 2 times.One for Apps tier and other from DB tier.If we miss DB tier we can see similar output

Where target java version is higher than existing

2026.08         action  Your Version  bitness Java Location

 -------------- -------- ------------  ------- ---------------

 1.8.0_501               1.8.0_501      64-bit OJVM In database

 1.8.0_503         j)    1.8.0_491      64-bit /u01/ebsdev/db/tech_st/12.2.0.3/jdk/bin/java

 1.8.0_503         u)    1.8.0_491     64-bit /u01/ebsdev/db/tech_st/12.2.0.3/appsutil/jre/bin/java

 

j) Apply the Database Release Update (DBRU) recommended by the latest EBS CPU MOS Note referenced in Article KA923  and the JDK patch listed in Article KB118730

u) When the DB JDK version is updated to the latest - then follow section 3 of Article KA1058 to update this JRE

 

Ø  Patch 35583866 :After extraction we can see ECPUC.sql.When we run this script under APPS user we can see similar output and these patches needs to be applied using adop utility

The following patches are required for latest EBS CPU and CSPU

--------------------------------------------------------------

39700255:12.2.0  - This is the CSPU patch rest of the patch are EBS product specific patches

39788590:R12.ATG_PF.C

39836567:R12.SCM_PF.C

39836607:R12.CC_PF.C

39836642:R12.FIN_PF.C

39393465:R12.PO.D

39836107:R12.HR_PF.C

 

Now we understand how to find list of patches needs to be applied.In the next section we shall discuss sequence of patches and details.

1.       Patch DBRU,OJVM and one off (if required)

2.       Patch Java in app and DB tier to the version identified by ejcpuc.sh

3.       Install middleware patches

4.       Install EBS patches

Patch database:

Follow the document KA989, Oracle E-Business Suite Release 12.2: Consolidated List of Oracle Database Patches and Bug Fixes

Please download the latest OPatch version from My Oracle Support (MOS) using the next reference:

Patch 6880880

Or using the next URL:

https://updates.oracle.com/download/6880880.html

stop database and listener.

Unzip that patch and navigate to patch top directory

Use opatch apply command to apply DB RU

Execute datapatch so that SQL patch registry is updated

Patch Java:

Follow below document for upgrading java

Using JDK 7.0 Latest Update with Oracle E-Business Suite Release 12.2 - Classic Tech Stack (1530033.1) KA1058

 Before applying java patch we need to run adop phase=fs_clone which will sync patch file system from run file system.

Then we start adop phase=prepare

Always apply java upgrade in patch file system .

Get java homes/path identified by ejcpuc.sh where we need to extracted jdk

Once it is upgraded we need to relink libraries under forms and reports home.

Then we run adop phase=cutover so that patch file system becomes run file system

Install middleware patches:

For middleware patches, refer to Oracle E-Business Suite Release 12.2: Patching Technology Components Guide KA1134

Consolidated List of Oracle Fusion Middleware Patches and Bug Fixes for Oracle E-Business Suite Release 12.2 - Classic Tech Stack KA988

Before applying middleware patches start adop phase prepapre

For WLS patch we have to use bsu.sh(smart utility) and we need to bounce app tier stack so that change is in effect

Install EBS patches:

Read patch readme for CSPU patches.

For example august 2026 CSPU patches 2 pre-requiste patches for AD and TXK patches

Multiple patches can be run together like below

adop phase=apply patches=39788590,39836567,39836607,39836642,39393465,39836107 patchtop=<patch_top_directory>

Finish the patch cycle after apply

adop phase=finalize

adop phase=cutover

adop phase=cleanup

 

Hope we have now better understanding of how to apply EBS patches and we can create our own document.

 


 

 

How to integrate oracle SQL-cL MCP server using VS code

Ø   Introduction Model Context Protocol (MCP) has emerged as a popular standard for enabling communication between AI agents and external ...