Forum Discussion
Establish an Oracle Database Connection hosted on Azure VM via AI Foundry Agent
Recommended approaches
AI Foundry (Intent + Orchestration)
- Parse user Intent (AWR Report, locking sesson RMAN faliure , active sessions)
- Extract params (DB Name, date, time window, subscriont, RG)
- Select the correct query template id (not raw sql)
Second - (Knowledge Base (Query Template)
- AWR_REPORT
- LOCKING_SESSION
- RMAN_FALIURES
- ACTIVE_SESSION
Third - (Tool layer - Oracle Execution)
Accepts: OperationId (get_awrt_report)
parameters: (Date, time range, db name)
executes only white listed SQL Templates
Oracle connectivity can also be a better approach; you can use Python-oracledb, a read-only DBA user, etc.
Example: Query--> DBA_HIST_* views /generated report via standard AWR script
time window (xAM-yPM on a date) map to snapshot id
The following could be your workflow (production safe approach)
User →
AI Foundry Agent →
Select Query Template (KB) →
Call Oracle Ops API (Tool) →
Execute on Oracle →
Return results →
GPT‑4.1 analysis