SQLite VDBE opcode

Ge

This works just like the Lt opcode except that the jump is taken if the content of register P3 is greater than or equal to the content of register P1.

Jumps: P2 is an instruction address. In the listings here, a jump is drawn as an arc and the address is a link.

An example

6 of the 178 statements we compiled against the sample database use Ge. This is the one with the shortest program; the rows that use Ge are highlighted.

SELECT * FROM tracks WHERE ms < bytes
addropcodep1p2p3p4p5
0Init01600
1OpenRead04060
2Rewind01500
3Column0310
4Column0420
5Ge2141BINARY-883
6Rowid0300
7Column0140
8Column0250
9Column0360
10Column0470
11Column0580
12RealAffinity8000
13ResultRow3600
14Next0301
15Halt0000
16Transaction00101
17Goto0100

Open it in the EXPLAIN visualizer →

Also in this program: Column, Goto, Halt, Init, Next, OpenRead, RealAffinity, ResultRow, Rewind, Rowid, Transaction.

What the SQLite documentation says

This works just like the Lt opcode except that the jump is taken if the content of register P3 is greater than or equal to the content of register P1. See the Lt opcode for additional information.

From sqlite.org's list of opcodes for SQLite 3.54.1, in the public domain. Opcodes are not a stable interface and change between releases.

← Function · GetSubtype →