Presentation is loading. Please wait.

Presentation is loading. Please wait.

Sql*Plus Oracle Server ResultQuery, Procedure Call.

Similar presentations


Presentation on theme: "Sql*Plus Oracle Server ResultQuery, Procedure Call."— Presentation transcript:

1 Sql*Plus Oracle Server ResultQuery, Procedure Call

2 Demo_Test : Measured Temperature Values a0a1a2a3a4 4548556560 4352576361 4751586059 4042575556 3536474641 3637495048 Demo_Test : Measured Temperature Values a0a1a2a3a4 4548556560 4352576361 4751586059 4042575556 3536474641 3637495048 Results a0a1a2a3a4 00240

3 Client Server Call isk_demo.PosCount() ; Package isk_demo { MaxPos() ; PosCount() ; } Table : Demo_Test... Results Executing sp… Call isk_demo.PosCount() ; Package isk_demo { MaxPos() ; PosCount() ; }

4 Create Or Replace Package isk_demo As Function MaxPos(t1 Float, t2 Float, t3 Float, t4 Float, t5 Float) Return Integer ; Pragma Restrict_References(MaxPos, WNDS) ; Procedure PosCount ; End isk_demo ; Create Or Replace Package Body isk_demo As End isk_demo ;

5 Create Or Replace Package Body isk_demo As Function MaxPos(…) Return Integer Procedure PosCount As Cursor rSet Is Select a0, a1, a2, a3, a4 From demo_test ; Type PosCountArrayType Is Varray(5) Of Integer ; PosCountArray PosCountArrayType := PosCountArrayType() ; I Integer ; Begin For rSetRow In rSet Loop I := MaxPos(rSetRow.a0, rSetRow.a1, rSetRow.a2, rSetRow.a3, rSetRow.a4) ; PosCountArray(I) := PosCountArray(I) + 1 ; End Loop ; End PosCount ; End isk_demo ;


Download ppt "Sql*Plus Oracle Server ResultQuery, Procedure Call."

Similar presentations


Ads by Google