# Săpt 2 Notes — Oracle OUT Param Probe **Script**: `poc/async_out_param_probe.py` **Date**: 2026-04-11 **Status**: PASSED ✅ ## Latency (measured 2026-04-11) | Operation | Time | |-----------|------| | connect | 21.9ms | | CREATE PROCEDURE | 9.2ms | | callproc (OUT param) | 1.0ms | | DROP PROCEDURE | 54.6ms | | **Total** | **87.5ms** | ## OUT Param Result - Procedure: `MARIUSM_AUTO.test_out(p OUT NUMBER)` sets `p := 42` - Python: `cursor.var(oracledb.NUMBER)` → `cursor.callproc(...)` → `out_var.getvalue()` = **42.0** - Assert `== 42`: **PASSED** ## Cleanup - `DROP PROCEDURE MARIUSM_AUTO.test_out` executed successfully - Cleanup OK ✅ — no residual objects left in schema ## Key Findings - `oracledb.cursor.var(oracledb.NUMBER)` correctly round-trips Oracle `OUT NUMBER` parameters - The returned value from `.getvalue()` is a Python `float` (42.0), so `int()` cast is needed for IDs - `callproc` latency is ~1ms once connected — Oracle OUT params add negligible overhead - DDL (CREATE/DROP) requires ~10-55ms each — avoid in hot paths - This pattern matches exactly what `ComandaService.creeaza_comanda()` uses for `out_id_ordl` and `out_nrord`