Lines Matching defs:pStr

21595 SQLITE_PRIVATE   void sqlite3VdbeMemPrettyPrint(Mem *pMem, StrAccum *pStr);
78464 DblquoteStr *pStr = sqlite3DbMallocRawNN(db,
78465 sizeof(*pStr)+n+1-sizeof(pStr->z));
78466 if( pStr ){
78467 pStr->pNextStr = p->pDblStr;
78468 p->pDblStr = pStr;
78469 memcpy(pStr->z, z, n+1);
78484 DblquoteStr *pStr;
78487 for(pStr=pVdbe->pDblStr; pStr; pStr=pStr->pNextStr){
78488 if( strcmp(zId, pStr->z)==0 ) return 1;
86357 SQLITE_PRIVATE void sqlite3VdbeMemPrettyPrint(Mem *pMem, StrAccum *pStr){
86375 sqlite3_str_appendf(pStr, "%cx[", c);
86377 sqlite3_str_appendf(pStr, "%02X", ((int)pMem->z[i] & 0xFF));
86379 sqlite3_str_appendf(pStr, "|");
86382 sqlite3_str_appendchar(pStr, 1, (z<32||z>126)?'.':z);
86384 sqlite3_str_appendf(pStr,"]");
86386 sqlite3_str_appendf(pStr, "+%dz",pMem->u.nZero);
86403 sqlite3_str_appendf(pStr, " %c%d[", c, pMem->n);
86406 sqlite3_str_appendchar(pStr, 1, (c>=0x20&&c<=0x7f) ? c : '.');
86408 sqlite3_str_appendf(pStr, "]%s", encnames[pMem->enc]);
143945 ** pStr holds the text of an expression that we are building up one term
143951 StrAccum *pStr, /* The text expression being built */
143961 if( bAnd ) sqlite3_str_append(pStr, " AND ", 5);
143963 if( nTerm>1 ) sqlite3_str_append(pStr, "(", 1);
143965 if( i ) sqlite3_str_append(pStr, ",", 1);
143966 sqlite3_str_appendall(pStr, explainIndexColumnName(pIdx, iTerm+i));
143968 if( nTerm>1 ) sqlite3_str_append(pStr, ")", 1);
143970 sqlite3_str_append(pStr, zOp, 1);
143972 if( nTerm>1 ) sqlite3_str_append(pStr, "(", 1);
143974 if( i ) sqlite3_str_append(pStr, ",", 1);
143975 sqlite3_str_append(pStr, "?", 1);
143977 if( nTerm>1 ) sqlite3_str_append(pStr, ")", 1);
143982 ** function appends text to pStr that describes the subset of table
143994 static void explainIndexRange(StrAccum *pStr, WhereLoop *pLoop){
144001 sqlite3_str_append(pStr, " (", 2);
144004 if( i ) sqlite3_str_append(pStr, " AND ", 5);
144005 sqlite3_str_appendf(pStr, i>=nSkip ? "%s=?" : "ANY(%s)", z);
144010 explainAppendTerm(pStr, pIndex, pLoop->u.btree.nBtm, j, i, ">");
144014 explainAppendTerm(pStr, pIndex, pLoop->u.btree.nTop, j, i, "<");
144016 sqlite3_str_append(pStr, ")", 1);
163533 ** Insert a single space character into pStr if the current string
163536 static void addSpaceSeparator(sqlite3_str *pStr){
163537 if( pStr->nChar && sqlite3IsIdChar(pStr->zText[pStr->nChar-1]) ){
163538 sqlite3_str_append(pStr, " ", 1);
163560 sqlite3_str *pStr; /* The normalized SQL string under construction */
163565 pStr = sqlite3_str_new(db);
163566 assert( pStr!=0 ); /* sqlite3_str_new() never returns NULL */
163567 for(i=0; zSql[i] && pStr->accError==0; i+=n){
163579 sqlite3_str_append(pStr, " NULL", 5);
163589 sqlite3_str_append(pStr, "?", 1);
163595 iStartIN = pStr->nChar;
163598 sqlite3_str_append(pStr, "(", 1);
163603 assert( pStr->nChar>=(u32)iStartIN );
163604 pStr->nChar = iStartIN+1;
163605 sqlite3_str_append(pStr, "?,?,?", 5);
163609 sqlite3_str_append(pStr, ")", 1);
163614 j = pStr->nChar;
163622 sqlite3_str_append(pStr, "?", 1);
163628 addSpaceSeparator(pStr);
163629 sqlite3_str_append(pStr, zId, nId);
163631 sqlite3_str_appendf(pStr, "\"%w\"", zId);
163635 addSpaceSeparator(pStr);
163636 sqlite3_str_append(pStr, zSql+i, n);
163638 while( j<pStr->nChar ){
163639 pStr->zText[j] = sqlite3Tolower(pStr->zText[j]);
163649 if( sqlite3IsIdChar(zSql[i]) ) addSpaceSeparator(pStr);
163650 j = pStr->nChar;
163651 sqlite3_str_append(pStr, zSql+i, n);
163652 while( j<pStr->nChar ){
163653 pStr->zText[j] = sqlite3Toupper(pStr->zText[j]);
163660 if( tokenType!=TK_SEMI ) sqlite3_str_append(pStr, ";", 1);
163661 return sqlite3_str_finish(pStr);
186625 StrBuffer *pStr, /* Buffer to append to */
186637 if( pStr->n+nAppend+1>=pStr->nAlloc ){
186638 sqlite3_int64 nAlloc = pStr->nAlloc+(sqlite3_int64)nAppend+100;
186639 char *zNew = sqlite3_realloc64(pStr->z, nAlloc);
186643 pStr->z = zNew;
186644 pStr->nAlloc = nAlloc;
186646 assert( pStr->z!=0 && (pStr->nAlloc >= pStr->n+nAppend+1) );
186649 memcpy(&pStr->z[pStr->n], zAppend, nAppend);
186650 pStr->n += nAppend;
186651 pStr->z[pStr->n] = '\0';
190454 JsonString *pStr;
190456 pStr = (JsonString*)sqlite3_aggregate_context(ctx, sizeof(*pStr));
190457 if( pStr ){
190458 if( pStr->zBuf==0 ){
190459 jsonInit(pStr, ctx);
190460 jsonAppendChar(pStr, '[');
190461 }else if( pStr->nUsed>1 ){
190462 jsonAppendChar(pStr, ',');
190463 pStr->pCtx = ctx;
190465 jsonAppendValue(pStr, argv[0]);
190469 JsonString *pStr;
190470 pStr = (JsonString*)sqlite3_aggregate_context(ctx, 0);
190471 if( pStr ){
190472 pStr->pCtx = ctx;
190473 jsonAppendChar(pStr, ']');
190474 if( pStr->bErr ){
190475 if( pStr->bErr==1 ) sqlite3_result_error_nomem(ctx);
190476 assert( pStr->bStatic );
190478 sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed,
190479 pStr->bStatic ? SQLITE_TRANSIENT : sqlite3_free);
190480 pStr->bStatic = 1;
190482 sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed, SQLITE_TRANSIENT);
190483 pStr->nUsed--;
190514 JsonString *pStr;
190517 pStr = (JsonString*)sqlite3_aggregate_context(ctx, 0);
190519 /* pStr is always non-NULL since jsonArrayStep() or jsonObjectStep() will
190521 if( NEVER(!pStr) ) return;
190523 z = pStr->zBuf;
190525 if( i>=pStr->nUsed ){
190526 pStr->nUsed = 1;
190538 pStr->nUsed -= i;
190539 memmove(&z[1], &z[i+1], (size_t)pStr->nUsed-1);
190556 JsonString *pStr;
190560 pStr = (JsonString*)sqlite3_aggregate_context(ctx, sizeof(*pStr));
190561 if( pStr ){
190562 if( pStr->zBuf==0 ){
190563 jsonInit(pStr, ctx);
190564 jsonAppendChar(pStr, '{');
190565 }else if( pStr->nUsed>1 ){
190566 jsonAppendChar(pStr, ',');
190567 pStr->pCtx = ctx;
190571 jsonAppendString(pStr, z, n);
190572 jsonAppendChar(pStr, ':');
190573 jsonAppendValue(pStr, argv[1]);
190577 JsonString *pStr;
190578 pStr = (JsonString*)sqlite3_aggregate_context(ctx, 0);
190579 if( pStr ){
190580 jsonAppendChar(pStr, '}');
190581 if( pStr->bErr ){
190582 if( pStr->bErr==1 ) sqlite3_result_error_nomem(ctx);
190583 assert( pStr->bStatic );
190585 sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed,
190586 pStr->bStatic ? SQLITE_TRANSIENT : sqlite3_free);
190587 pStr->bStatic = 1;
190589 sqlite3_result_text(ctx, pStr->zBuf, (int)pStr->nUsed, SQLITE_TRANSIENT);
190590 pStr->nUsed--;
190763 /* Append the name of the path for element i to pStr
190767 JsonString *pStr, /* Write the path here */
190773 jsonAppendChar(pStr, '$');
190777 jsonEachComputePath(p, pStr, iUp);
190781 jsonPrintf(30, pStr, "[%d]", pUp->u.iKey);
190787 jsonPrintf(pNode->n+1, pStr, ".%.*s", pNode->n-2, pNode->u.zJContent+1);