RDB/VMS Relational Database Operator PLACE — VMS RDB_3.1A
Returns the dbkey of a specified record. The PLACE statement lets you determine the target page number for records that are to be loaded into the database. The PLACE statement is similar in syntax to the STORE statement. However, the PLACE statement does not actually store a record. The PLACE statement can result in significant performance improvements in database load procedures that specify the PLACEMENT VIA INDEX clause for a hashed index. Use it only with records for which a hashed index has been defined. The PLACE statement is valid only in RDO and in Callable RDO.
Additional information available:
Format
PLACE ─>context-var ──>
I
N ──┬────────>─────────┬──> relation-name ──────┐ └─>db-handle ─> . ─┘ │ │ ┌──────────────────────────────────<────────────────────────────────────┘ └─────────>
U
S
I
N
G ───┬────────────────┬─────────────────────────────────┐ └──> on-error ───┘ │ ┌────────────────────────────────<──────────────────────────────────────┘ ├──┬──> context-var . field-name ───> typebox (=) ───> value-expr ───┬─>─┬───>────┐ │ └───────────────────────── typebox (;) <──────────────────────────┘ │ │ └─────> context-var . * ──────────> typebox (=) ──> record-descr ────>───┘ │ ┌──────────────────<──────────────────────<─────────────────────────────┘ └─┬─>─────────────────────────────>───────────────────────────────────┬─┐ ├─>
G
E
T ──> host-var ──> typebox (=) ──> context-var ──> . ──>
R
D
B
$
D
B
K
E
Y ─┤ │ └─>
P
R
I
N
T ─────────────────────> context-var ──> . ──>
R
D
B
$
D
B
K
E
Y ─┘ │ ┌───────────────────<──────────────────────────<────────────────────────┘ └──────────>────────────────────>
E
N
D
P
L
A
C
E
Additional information available:
context-vardb-handlerelation-nameon-errorfield-namevalue-expr
record-descrhost-var
context-var
A valid context variable.
db-handle
A host language variable used to refer to the database.
relation-name
The name of the relation into which the value would be stored.
on-error
The ON ERROR clause, which specifies a host language statement or Rdb/VMS data manipulation statement to be performed if an Rdb/VMS error occurs.
field-name
The names of the fields that appear in the index referenced in the DEFINE STORAGE MAP statement's PLACEMENT VIA INDEX clause. All index segments must be specified or the results of the PLACE statement will be of little use. Field-names not used in the index, if listed, will be ignored.
value-expr
A valid Rdb/VMS value expression that specifies the value that would be stored.
record-descr
A valid data dictionary record descriptor matching all the fields of the relation. You can use a host language statement to include the relation definition in your program. Each field of the record descriptor must match exactly the field names and data types of the fields in the Rdb/VMS relation referenced by the context variable.
host-var
A user-defined host language variable, into which you may store the dbkey of the record that would be stored. Use the GET...RDB$DB_KEY construct to assign the value of the dbkey to the host language variable.
Example
The PLACE statement returns the dbkey of the specified record in the following example: RDO> PLACE E IN EMPLOYEES cont> USING E.EMPLOYEE_ID = "94789" cont> PRINT E.RDB$DB_KEY cont> END_PLACE