Function
This instruction is used to get the status of the DB Connection specified in the DBConnection input variable. The
current status is output to the ConnectionStatus output variable.
Refer to the â– ServiceStatus of A-1-2 Variables Used in the DB Connection Instructions for the status.
Refer to Section B-2-3 How to Measure DB Response Time for the measurement of the DB response time.
Precautions for Correct Use
ï‚– Execution of this instruction is continued until processing is completed even if the value of Execute changes to
FALSE or the execution time exceeds the task period. The value of Done changes to TRUE when processing
is completed. Use this to confirm normal completion of processing.
ï‚– Refer to Using this Section of the NJ/NX-series Instructions Reference Manual (Cat. No. W502) for a timing
chart for Execute, Done, Busy, and Error.
ï‚– This instruction cannot be used on an event task. A compiling error will occur.
ï‚– If you execute this instruction before completion of a DB_Connect instruction and confirm that the connection
status of the DB Connection is Connected, an instruction error (Invalid DB Connection) may occur when you
execute the next DB Connection Instruction. When you use the DBConnection output variable from the
DB_Connect instruction, confirm that the Done output variable of the DB_Connect instruction is TRUE or the
value of the DBConnection output variable is not 16#00000000 before executing the DB Connection
Instruction.
ï‚– An error occurs for this instruction in the following cases. Error will be TRUE.
ï‚– When the instruction was executed when the DB Connection Service was not running
ï‚– When the instruction was executed while the initialization processing of the DB Connection Service
was in progress