Home | History | Annotate | Download | only in orig

Lines Matching refs:Blob

507 ** [sqlite3_blob_close | close] all [BLOB handles], and 
511 ** outstanding [prepared statements], [BLOB handles], and/or
513 ** of resources is deferred until all [prepared statements], [BLOB handles],
637 #define SQLITE_TOOBIG 18 /* String or BLOB exceeds size limit */
3377 ** <dd>The maximum size of any string or BLOB or table row, in bytes.<dd>)^
3722 ** ^The fifth argument to the BLOB and string binding interfaces
3723 ** is a destructor used to dispose of the BLOB or
3725 ** to dispose of the BLOB or string even if the call to bind API fails.
3741 ** ^The sqlite3_bind_zeroblob() routine binds a BLOB of length N that
3746 ** [sqlite3_blob_open | incremental BLOB I/O] routines.
3747 ** ^A negative value for the zeroblob results in a zero-length BLOB.
3761 ** ^[SQLITE_TOOBIG] might be returned if the size of a string or BLOB
4100 ** <li> BLOB
4158 ** ^If the result is a BLOB or UTF-8 string then the sqlite3_column_bytes()
4159 ** routine returns the number of bytes in that BLOB or string.
4167 ** ^If the result is a BLOB or UTF-16 string then the sqlite3_column_bytes16()
4168 ** routine returns the number of bytes in that BLOB or string.
4184 ** value from sqlite3_column_blob() for a zero-length BLOB is a NULL pointer.
4208 ** <tr><td> NULL <td> BLOB <td> Result is a NULL pointer
4211 ** <tr><td> INTEGER <td> BLOB <td> Same as INTEGER->TEXT
4214 ** <tr><td> FLOAT <td> BLOB <td> [CAST] to BLOB
4217 ** <tr><td> TEXT <td> BLOB <td> No change
4218 ** <tr><td> BLOB <td> INTEGER <td> [CAST] to INTEGER
4219 ** <tr><td> BLOB <td> FLOAT <td> [CAST] to REAL
4220 ** <tr><td> BLOB <td> TEXT <td> Add a zero terminator if needed
4231 ** <li> The initial content is a BLOB and sqlite3_column_text() or
4768 ** an application-defined function to be the BLOB whose content is pointed
4774 ** a BLOB containing all zero bytes and N bytes in size.
4803 ** error indicating that a string or BLOB is too long to represent.
4843 ** function as the destructor on the text or BLOB result when it has
4847 ** assumes that the text or BLOB result is in constant space and does not
6054 ** CAPI3REF: A Handle To An Open BLOB
6055 ** KEYWORDS: {BLOB handle} {BLOB handles}
6057 ** An instance of this object represents an open BLOB on which
6058 ** [sqlite3_blob_open | incremental BLOB I/O] can be performed.
6062 ** can be used to read or write small subsections of the BLOB.
6063 ** ^The [sqlite3_blob_bytes()] interface returns the size of the BLOB in bytes.
6068 ** CAPI3REF: Open A BLOB For Incremental I/O
6072 ** ^(This interfaces opens a [BLOB handle | handle] to the BLOB located
6074 ** in other words, the same BLOB that would be selected by:
6086 ** ^If the flags parameter is non-zero, then the BLOB is opened for read
6087 ** and write access. ^If the flags parameter is zero, the BLOB is opened for
6090 ** ^(On success, [SQLITE_OK] is returned and the new [BLOB handle] is stored
6104 ** a TEXT or BLOB value)^,
6106 ** constraint and the blob is being opened for read/write access)^,
6108 ** column zColumn is part of a [child key] definition and the blob is
6117 ** ^(If the row that a BLOB handle points to is modified by an
6119 ** then the BLOB handle is marked as "expired".
6121 ** other than the one the BLOB handle is open on.)^
6123 ** an expired BLOB handle fail with a return code of [SQLITE_ABORT].
6124 ** ^(Changes written into a BLOB prior to the BLOB expiring are not
6125 ** rolled back by the expiration of the BLOB. Such changes will eventually
6129 ** the opened blob. ^The size of a blob may not be changed by this
6131 ** blob.
6135 ** zero-filled blob to read or write using the incremental-blob interface.
6137 ** To avoid a resource leak, every open [BLOB handle] should eventually
6151 ** CAPI3REF: Move a BLOB Handle to a New Row
6154 ** ^This function is used to move an existing blob handle so that it points
6157 ** changed. ^The database, table and column on which the blob handle is open
6158 ** remain the same. Moving an existing blob handle to a new row can be
6162 ** it must exist and there must be either a blob or text value stored in
6164 ** it does not contain a blob or text value, or if another error occurs, an
6165 ** SQLite error code is returned and the blob handle is considered aborted.
6167 ** [sqlite3_blob_reopen()] on an aborted blob handle immediately return
6168 ** SQLITE_ABORT. ^Calling [sqlite3_blob_bytes()] on an aborted blob handle
6176 ** CAPI3REF: Close A BLOB Handle
6179 ** ^This function closes an open [BLOB handle]. ^(The BLOB handle is closed
6183 ** ^If the blob handle being closed was opened for read-write access, and if
6185 ** blob handles or active write statements, the current transaction is
6190 ** open blob handle results in undefined behaviour. ^Calling this routine
6193 ** is passed a valid open blob handle, the values returned by the
6199 ** CAPI3REF: Return The Size Of An Open BLOB
6202 ** ^Returns the size in bytes of the BLOB accessible via the
6203 ** successfully opened [BLOB handle] in its only argument. ^The
6204 ** incremental blob I/O routines can only read or overwriting existing
6205 ** blob content; they cannot change the size of a blob.
6207 ** This routine only works on a [BLOB handle] which has been created
6215 ** CAPI3REF: Read Data From A BLOB Incrementally
6218 ** ^(This function is used to read data from an open [BLOB handle] into a
6220 ** from the open BLOB, starting at offset iOffset.)^
6222 ** ^If offset iOffset is less than N bytes from the end of the BLOB,
6225 ** ^The size of the blob (and hence the maximum value of N+iOffset)
6228 ** ^An attempt to read from an expired [BLOB handle] fails with an
6234 ** This routine only works on a [BLOB handle] which has been created
6244 ** CAPI3REF: Write Data Into A BLOB Incrementally
6247 ** ^(This function is used to write data into an open [BLOB handle] from a
6249 ** into the open BLOB, starting at offset iOffset.)^
6257 ** ^If the [BLOB handle] passed as the first argument was not opened for
6261 ** This function may only modify the contents of the BLOB; it is
6262 ** not possible to increase the size of a BLOB using this API.
6263 ** ^If offset iOffset is less than N bytes from the end of the BLOB,
6265 ** BLOB (and hence the maximum value of N+iOffset) can be determined
6269 ** ^An attempt to write to an expired [BLOB handle] fails with an
6270 ** error code of [SQLITE_ABORT]. ^Writes to the BLOB that occurred
6271 ** before the [BLOB handle] expired are not rolled back by the
6273 ** have been overwritten by the statement that expired the BLOB handle
6276 ** This routine only works on a [BLOB handle] which has been created
8688 ** The maximum length of a TEXT or BLOB in bytes. This also
10098 ** BTREE_BLOBKEY, the key is an arbitrary BLOB and no content is stored
12098 ** for a numeric type is a single comparison. And the BLOB type is first.
12364 ** the key of an index. A blob encoding of a record is created by
15426 char *z; /* String or BLOB value */
15461 #define MEM_Blob 0x0010 /* Value is a BLOB */
15470 /* Whenever Mem contains a valid string or blob representation, one of
15480 #define MEM_Zero 0x4000 /* Mem.i contains count of 0s appended to blob */
25569 ** of a 1048569-byte BLOB or string.
25712 ** Convert a BLOB literal of the form "x'hhhhhh'" into its binary
26285 /* 28 */ "Blob" OpHelp("r[P2]=P4 (len=P1)"),
62438 ** expecting an index b-tree, then the caller should be inserting blob
62441 ** blob of associated data. */
63956 ** This function returns a pointer to a blob of memory associated with
63963 ** call the nBytes parameter is ignored and a pointer to the same blob
63966 ** If the nBytes parameter is 0 and the blob of memory has not yet been
63967 ** allocated, a null pointer is returned. If the blob has already been
63972 ** blob of allocated memory. The xFree function should not call sqlite3_free()
64084 ** Mark this cursor as an incremental blob cursor.
65007 /* If p holds a string or blob, the Mem.z must point to exactly
65012 ** (3) An ephemeral string or blob
65013 ** (4) A static string or blob
65073 ** blob if bPreserve is true. If bPreserve is false, any prior content
65081 ** contain a valid string or blob value. */
65124 ** Any prior string or blob content in the pMem object may be discarded.
65174 ** blob stored in dynamically allocated space.
65184 /* Set nByte to the number of bytes required to store the expanded blob. */
65231 ** are converted using sqlite3_snprintf(). Converting a BLOB to a string
65412 ** If pMem is a string or blob, then we make an attempt to convert
65440 ** value. If it is a string or blob, try to convert it to a double.
65551 case SQLITE_AFF_BLOB: { /* Really a cast to BLOB */
65622 ** Delete any previous value and set the value to be a BLOB of length
65696 ** Return true if the Mem object contains a TEXT or BLOB that is
65800 ** Change the value of a Mem to be a string or a BLOB.
65822 int iLimit; /* Maximum allowed string or blob size */
66379 ** record (a blob) containing the argument value.
67853 zP4 = "(blob)";
68121 ** initialized to a BLOB by the P4_SUBPROGRAM processing logic below */
68428 ** VdbeCursor/BtCursor structures. The blob of memory associated with
68430 ** stores the blob of memory associated with cursor 1, etc.
69591 ** 'serial-type' and a blob of data. The serial type is an 8-byte unsigned
69595 ** the blob of data that it corresponds to. In a table record, all serial
69598 ** serial-type and data blob separately.
69615 ** N>=12 and even (N-12)/2 BLOB
69735 ** Write the serialized data blob for the value stored in pMem into
69770 /* String or blob */
69793 ** Deserialize the data blob pointed to by buf as serial type serial_type
69905 /* EVIDENCE-OF: R-14606-31564 Value is a BLOB that is (N-12)/2 bytes in
70185 ** If one blob is a prefix of the other, then the shorter is the lessor.
70199 ** sequence pColl and finally blob's ordered by memcmp().
70249 /* If one value is a string and the other is a blob, the string is less.
70274 ** to the blob case and use memcmp(). */
70327 ** greater than key2. The {nKey1, pKey1} key must be a blob
70474 /* RHS is a blob */
70652 res = pPKey2->r2; /* (pKey1/nKey1) is a blob */
71157 ** point number string BLOB NULL
71232 ** result as a string or blob but if the string or blob is too large, it
71411 sqlite3VdbeMemSetStr(pCtx->pOut, "string or blob too big", -1,
72206 ** Bind a text or BLOB value.
72240 ** Bind a blob value to an SQL statement variable.
72785 int nOut; /* Number of bytes of the blob to include in output */
72837 ** not misused. A shallow copy of a string or blob just copies a
72838 ** pointer to the string or blob, not the content. If the original
72839 ** is changed while the copy is still in use, the string or blob might
72886 ** use this information to make sure that the zero-blob functionality
72911 ** Test a register to see if it exceeds the current maximum blob size.
72912 ** If it does, record the new maximum blob size.
72991 /* Find the memory cell that will be used to store the blob of memory
73103 ** representation (blob and NULL do not get converted) but no string
73142 ** pMem currently only holds a string type (or maybe a BLOB that we can
73969 ** the datatype of the register P2 is converted to BLOB. The content is
73970 ** the same sequence of bytes, it is merely interpreted as a BLOB instead
74024 ** instruction, but do not free any string or blob memory associated with
74025 ** the register, so that if the value was a string or blob that was
74035 /* Opcode: Blob P1 P2 * P4 *
74038 ** P4 points to a blob of data P1 bytes long. Store this
74039 ** blob in register P2.
74120 ** is made of any string or blob constant. See also OP_SCopy.
74149 ** is a string or blob, then the copy is only a pointer to the
74710 ** <li value="98"> BLOB
75451 ** 2. the length(X) function if X is a blob, and
75532 ** If P4 is NULL then all index fields have the affinity BLOB.
75670 pOut->enc = SQLITE_UTF8; /* In case the blob is ever converted to text */
75728 ** statements (i.e. open read/write incremental blob handles).
76588 ** blob, or NULL. But it needs to be an integer before we can do
76727 ** If P4==0 then register P3 holds a blob constructed by MakeRecord. If
76744 ** If P4==0 then register P3 holds a blob constructed by MakeRecord. If
76763 ** If P4==0 then register P3 holds a blob constructed by MakeRecord. If
77261 ** record blob in register P3 against a prefix of the entry that
77398 pOut->enc = SQLITE_UTF8; /* In case the blob is ever cast to text */
79559 /* Jump to here if a string or blob larger than SQLITE_MAX_LENGTH
79563 sqlite3VdbeError(p, "string or blob too big");
79612 ** This file contains code used to implement incremental BLOB I/O.
79626 int nByte; /* Size of open blob, in bytes */
79627 int iOffset; /* Byte offset of blob in cursor data */
79629 BtCursor *pCsr; /* Cursor pointing at blob row */
79637 ** the b-tree cursor associated with blob handle p to point to row iRow.
79642 ** contain a value of type TEXT or BLOB in the column nominated when the
79643 ** blob handle was opened, then an error code is returned and *pzErr may
79704 ** Open a blob handle.
79708 const char *zDb, /* The attached database containing the blob */
79709 const char *zTable, /* The table containing the blob */
79710 const char *zColumn, /* The column containing the blob */
79713 sqlite3_blob **ppBlob /* Handle for accessing the blob returned here */
79941 ** Close a blob handle that was previously created using
79962 ** Perform a read or write operation on a blob
79985 /* If there is no statement handle, then the blob-handle has
80011 ** Read data from a blob handle.
80018 ** Write data to a blob handle.
80025 ** Query a blob handle for the size of the data.
80036 ** Move an existing blob handle to point to a different row of the same
80040 ** contain a blob or text value, then an error code is returned and the
80055 /* If there is no statement handle, then the blob-handle has
80105 ** object. The row is a binary blob in the
80119 ** sqlite3VdbeSorterRowkey() Return the complete binary blob for the
80122 ** sqlite3VdbeSorterCompare() Compare the binary blob for the row
80124 ** another binary blob X and report if
80565 PmaReader *p, /* PmaReader from which to take the blob */
81610 ** Each record consists of a varint followed by a blob of data (the
81611 ** key). The varint is the number of bytes in the blob of data.
90129 ** of the INTEGER PRIMARY KEY. The sample column is a blob which is the
90157 ** of a blob encoding of the complete index key as is found in
90330 /* Initialize the BLOB value of a ROWID
90411 ** return value is BLOB, but it is really just a pointer to the Stat4Accum
90820 ** has type BLOB but it is really just a pointer to the Stat4Accum object.
93873 ** 'BLOB'. If there is a type specified, then sqlite3AddColumnType() will
93911 ** 'BLOB' | SQLITE_AFF_BLOB
93935 }else if( h==(('b'<<24)+('l'<<16)+('o'<<8)+'b') /* BLOB */
93968 *pszEst = v; /* BLOB(k), VARCHAR(k), CHAR(k) -> r=(k/4+1) */
93974 *pszEst = 5; /* BLOB, TEXT, CLOB -> r=5 (approx 20 bytes)*/
98657 case SQLITE_BLOB: z = "blob"; break;
98734 ** IMP: R-01992-00519 Abs(X) returns 0.0 if X is a string or blob
98827 ** If x is a blob, then we count bytes.
98966 ** If nByte is larger than the maximum string or blob length, then
99065 ** Implementation of randomblob(N). Return a random blob
99660 ** The hex() function. Interpret the argument as a blob. Return
99689 ** The zeroblob(N) function returns a zero-filled blob of size N bytes.
101843 ** 'A' BLOB
101908 ** 'A' BLOB
109564 ** final OP_Sequence column. The last column is the record as a blob.
113340 ** text or blob value. See ticket [883034dcb5].
118972 ** with equality constraints that use BLOB or NONE affinity are set to
118979 ** the right hand side of the equality constraint (t2.b) has BLOB/NONE affinity,
120219 ** that may only be NULL, a string, or a BLOB, never a number. (This means
126970 "INTEGER", "FLOAT", "BLOB", "VARIABLE",
127199 /* 191 */ "term ::= INTEGER|FLOAT|BLOB",
128761 case 191: /* term ::= INTEGER|FLOAT|BLOB */ yytestcase(yyruleno==191);
132159 /* SQLITE_TOOBIG */ "string or blob too big",
135769 sqlite3_blob *pSegments; /* Blob handle open on %_segments table */
136477 "(id INTEGER PRIMARY KEY, value BLOB);",
136522 "CREATE TABLE %Q.'%q_segments'(blockid INTEGER PRIMARY KEY, block BLOB);",
136532 "root BLOB,"
136539 "CREATE TABLE %Q.'%q_docsize'(docid INTEGER PRIMARY KEY, size BLOB);",
137768 char *zBlob = 0; /* Blob read from %_segments table */
139174 ** Return a blob which is a pointer to the cursor. */
139375 ** If the value passed as the third argument is a blob of size
139376 ** sizeof(Fts3Cursor*), then the blob contents are copied to the
140606 ** Entry 0 of the %_stat table is a blob containing (nCol+1) FTS3
144738 ** If the <pointer> argument is specified, it must be a blob value
144745 ** is a blob containing the pointer stored as the hash data corresponding
146037 sqlite3_blob *pBlob; /* If not NULL, blob handle to read node */
147055 ** CREATE TABLE %_segments(blockid INTEGER PRIMARY KEY, block BLOB)
147060 ** with the contents of the blob stored in the "block" column of the
147062 ** to the size of the blob in bytes before returning.
147072 ** sqlite3Fts3SegmentsClose() function. Reusing a blob handle is a handy
147073 ** performance improvement, but the blob handle should always be closed
147082 char **paBlob, /* OUT: Blob data in malloc'd buffer */
147083 int *pnBlob, /* OUT: Size of blob data */
147130 ** Close the blob handle at p->pSegments, if it is open. See comments above
147832 char *zRoot, /* Blob value for "root" field */
149180 ** Encode N integers as varints into a blob.
149185 char *zBuf, /* Write the BLOB here */
149196 ** Decode a blob of varints into N integers
149201 const char *zBuf, /* The BLOB containing the varints */
149202 int nBuf /* size of the BLOB */
149217 ** a blob of varints.
149224 char *pBlob; /* The BLOB encoding of the document size */
149225 int nBlob; /* Number of bytes in the BLOB */
149249 ** Record 0 of the %_stat table contains a blob consisting of N varints,
149270 char *pBlob; /* Storage for BLOB written into %_stat */
149271 int nBlob; /* Size of BLOB written into %_stat */
149272 u32 *a; /* Array of integers that becomes the BLOB */
149505 typedef struct Blob Blob;
149514 struct Blob {
149526 Blob key; /* Last key written to the current block */
149527 Blob block; /* Current block image */
149561 Blob term; /* Current term */
149575 static void blobGrowBuffer(Blob *pBlob, int nMin, int *pRc){
149705 Blob *pBlk = &pNode->block;
149752 ** stored in blob *pNode. The node need not contain any terms, but the
149762 ** If the size of the value in blob pPrev is zero, then this is the first
149775 Blob *pNode, /* Current node image to append to */
149776 Blob *pPrev, /* Buffer containing previous term written */
149936 ** the node would be stored as a blob in the "root" column of the %_segdir
149951 Blob *pBlock = &pWriter->aNodeWriter[1].block;
150378 static void fts3StartNode(Blob *pNode, int iHeight, sqlite3_int64 iChild){
150393 ** This function creates a new node image in blob object *pNew by copying
150400 Blob *pNew, /* OUT: Write new node image here */
150406 Blob prev = {0, 0, 0}; /* Previous term written to new node */
150460 Blob root = {0,0,0}; /* New root page image */
150461 Blob block = {0,0,0}; /* Buffer used for any other block */
150588 static int fts3IncrmergeHintStore(Fts3Table *p, Blob *pHint){
150607 ** If successful, populate blob *pHint with the value read from the %_stat
150611 static int fts3IncrmergeHintLoad(Fts3Table *p, Blob *pHint){
150640 ** Otherwise, append an entry to the hint stored in blob *pHint. Each entry
150648 Blob *pHint, /* Hint blob to append to */
150661 ** Read the last entry (most recently pushed) from the hint blob *pHint
150665 ** If no error occurs, return SQLITE_OK. If the hint blob in *pHint does
150668 static int fts3IncrmergeHintPop(Blob *pHint, i64 *piAbsLevel, int *pnInput){
150702 Blob hint = {0, 0, 0}; /* Hint read from %_stat table */
150703 int bDirtyHint = 0; /* True if blob 'hint' has been modified */
150753 ** is removed from the hint blob. */
154064 ** CREATE TABLE %_node(nodeno INTEGER PRIMARY KEY, data BLOB)
154378 ** operator tests that the first field of a blob operand matches this
154384 ** An instance of this structure (in the form of a BLOB) is returned by
155515 RtreeMatchArg *pBlob; /* BLOB returned by geometry function */
155517 int nBlob; /* Size of the geometry function blob */
155518 int nExpected; /* Expected size of the BLOB */
155520 /* Check that value is actually a blob. */
155523 /* Check that the blob is roughly the right size. */
155620 /* A MATCH operator. The right-hand-side must be a blob that
157091 "CREATE TABLE \"%w\".\"%w_node\"(nodeno INTEGER PRIMARY KEY, data BLOB);"
157309 ** to the rtree (between 1 and 5, inclusive) and (2) a blob of data containing
157366 ** from the front of a blob that is an r-tree node. For example:
157429 ** This routine frees the BLOB that is returned by geomCallback().
157448 ** as a BLOB.
157450 ** The R-Tree MATCH operator will read the returned BLOB, deserialize
158611 ** to be a "fossil delta" - a patch to be applied to a blob value in the
158613 ** the existing value within the target database table must be of type BLOB.
159351 ** This function applies a fossil delta patch to a blob. Exactly two
159352 ** arguments must be passed to this function. The first is the blob to
159354 ** function returns the patched blob.
161012 ** blob starting at byte offset 40.
163573 ** a BLOB, but there is no support for JSONB in the current implementation.
163875 sqlite3_result_error(p->pCtx, "JSON cannot hold BLOB values", -1);
164743 ** is a BLOB, throw an error.
164852 ** is not a string or if any value is a BLOB, throw an error.
166532 ** If the bCommit flag is true, also close any open blob handles.
172535 ** CREATE TABLE %_data(id INTEGER PRIMARY KEY, block BLOB);
172582 ** blob: first term data
172587 ** blob: nNew bytes of new term data
172650 ** blob: first term data
172726 ** Each time a blob is read from the %_data table, it is padded with this
172773 sqlite3_blob *pReader; /* RO incr-blob open on %_data table */
173046 ** Compare the contents of the pLeft buffer with the pRight/nRight blob.
173097 ** Close the read-only blob handle, if it is open.
173121 ** rollback since it was last used. In this case a new blob handle
173134 /* If the blob handle is not open at this point, open it and seek
173146 ** table, missing row, non-blob/text in block column - indicate
173151 u8 *aOut = 0; /* Read blob data into this buffer */
176906 ** and the initial version of the "averages" record (a zero-byte blob).
176940 pConfig, "data", "id INTEGER PRIMARY KEY, block BLOB", 0, pzErr
178038 /* Make a copy of the second argument (a blob) in aBlob[]. The aBlob[]
180248 ** Return a "position-list blob" corresponding to the current position of
180249 ** cursor pCsr via sqlite3_result_blob(). A position-list blob contains
180253 ** A position-list blob begins with (nPhrase-1) varints, where nPhrase is
180260 ** as it can be derived from the total size of the blob.
181020 pConfig, "docsize", "id INTEGER PRIMARY KEY, sz BLOB", 0, pzErr
181471 Fts5Buffer buf; /* Buffer used to build up %_docsize blob */
183483 ** of a 1048569-byte BLOB or string.