IP Library Granted Patent US 8,805,821
Granted Patent B2
US 8,805,821 · App. 12/346,053 · Granted Aug 12, 2014

Deferred compilation of stored procedures

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,805,821
App. No.
12/346,053
Granted
Aug 12, 2014
Kind
B2
Abstract

A system, method, and computer program product are provided for compiling a stored procedure in a database. The compiling includes the steps of invoking the stored procedure, the stored procedure comprising one or more statements, substituting run-time values for one or more variables in the statements, and creating an access plan for the statements having the substituted run-time values.

Claims (32)

1. A method comprising:

invoking a stored procedure in a database, the stored procedure comprising one or more uncompiled database query statements marked for deferred compilation until the stored procedure is invoked at run-time, wherein at least one of the uncompiled database query statements includes one or more variables, and wherein statements marked for deferred compilation are selected for marking based on deferred compilation criteria;

substituting, at run-time, run-time values for the one or more variables in the statements; and

creating, at run-time, an access plan for the statements, wherein the access plan accounts for the statements having the substituted run-time values.

2. The method of claim 1 , further comprising:

optimizing the stored procedure.

3. The method of claim 1 , further comprising:

processing the statements.

4. The method of claim 1 , wherein the deferred compilation criteria comprises whether a statement includes a variable or parameter.

5. The method of claim 1 , wherein the deferred compilation criteria comprises whether a statement includes a JOIN operation with a temporary table created in the stored procedure.

6. A system comprising:

a memory configured to store modules comprising:

an invoking module to invoke a stored procedure in a database, the stored procedure comprising one or more uncompiled database query statements marked for deferred compilation until the stored procedure is invoked at run-time, wherein at least one of the uncompiled database query statements includes one or more variables, and wherein statements marked for deferred compilation are selected for marking based on deferred compilation criteria,

a substituting module to substitute, at run-time, run-time values for one or more variables in the statements, and

creating, at run-time, an access plan for the statements, wherein the access plan accounts for the statements having the substituted run-time values; and

one or more processors configured to process the modules.

7. The system of claim 6 , further comprising:

an optimizing module to optimize the stored procedure.

8. The system of claim 6 , further comprising:

a processing module to process the statements.

9. The system of claim 6 , wherein the deferred compilation criteria comprises whether a statement includes a variable or parameter.

10. The system of claim 6 , wherein the deferred compilation criteria comprises whether a statement includes a JOIN operation with a temporary table created in the stored procedure.

11. A computer-usable medium having computer-executable instructions stored thereon for compiling a stored procedure in a database, execution of which, by a computing device, causes the computing device to perform operations comprising:

invoking the stored procedure, the stored procedure comprising one or more uncompiled database query statements marked for deferred compilation until the stored procedure is invoked at run-time, wherein at least one of the uncompiled database query statements includes one or more variables, and wherein statements marked for deferred compilation are selected for marking based on deferred compilation criteria;

substituting, at run-time, run-time values for one or more variables in the statements; and

creating, at run-time, an access plan for the statements, wherein the access plan accounts for the statements having the substituted run-time values.

12. The computer-usable medium of claim 11 , the operations further comprising:

optimizing the stored procedure.

13. The computer-usable medium of claim 11 , the operations further comprising:

processing the statements.

14. The computer-usable medium of claim 11 , wherein the deferred compilation criteria comprises whether a statement includes a variable or parameter.

15. The computer-usable medium of claim 11 , wherein the deferred compilation criteria comprises whether a statement includes a JOIN operation with a temporary table created in the stored procedure.

Assignments (3)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 13, 2021
From: SYBASE, INC.
To: SERVICENOW, INC.
Reel/Frame 054907/0520 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 13, 2021
From: SAP SE
To: SERVICENOW, INC.
Reel/Frame 054907/0957 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 30, 2008
From: SARAPUK, ANDRZEJ
To: SYBASE, INC.
Reel/Frame 022040/0107 →