# 9. SQL Procedure Language Guide

Chapter Contents | Prev | Next
Keyword Search:
www.openlinksw.com
docs.openlinksw.com
Book Home
Contents
Preface
SQL Procedure Language Guide
General Principles
Scope of Declarations
Data Types
Handling Result Sets
Result Sets and Array Parameters
Exception Semantics
Virtuoso/PL Syntax
CREATE ASSEMBLY Syntax - External Libraries
CREATE PROCEDURE Syntax - External hosted procedures
Asynchronous Execution and Multithreading in Virtuoso/PL
Performance Tips
Remember the following:
Procedures and Transactions
Distributed Transaction & Two Phase Commit
Triggers
Character Escaping
Virtuoso/PL Scrollable Cursors
Virtuoso PL Modules
Handling Conditions In Virtuoso/PL Procedures
Procedure Language Debugger
Row Level Security

## 9.11. Performance Tips

### 9.11.1. Remember the following:

- Reference parameters (inout and out) are faster then value parameters (in).

- Use cursors and positioned delete/update (where current of) for read-modify transactions instead of a select .. into and searched update.

- Make an EXCLUSIVE read in read-modify transactions.

- When using ORDER BY and wishing to use a particular index, specify ALL key parts of the index, including those that have a '=' condition. If you want to have descending order using an index, specify DESC on ALL key parts.

Previous Asynchronous Execution and Multithreading in Virtuoso/PL | Chapter Contents | Next Procedures and Transactions