diff options
author | drh <> | 2023-06-13 18:10:52 +0000 |
---|---|---|
committer | drh <> | 2023-06-13 18:10:52 +0000 |
commit | e30ecbfb849aa20961d72567b3106bd0a8ca1883 (patch) | |
tree | 2df5fe894b49ad07d46202fa7243c37b52d1e1df /src/expr.c | |
parent | d34ce818676003c31ae59f643336756665a1d9cc (diff) | |
download | sqlite-e30ecbfb849aa20961d72567b3106bd0a8ca1883.tar.gz sqlite-e30ecbfb849aa20961d72567b3106bd0a8ca1883.zip |
Improved sqlite3_error_offset() values for bare column errors on '*' and
'table.*' expressions in SELECT statements.
FossilOrigin-Name: 118fe600876686273f85d0a080a21267e83c11826365f3220336b1bd39562518
Diffstat (limited to 'src/expr.c')
-rw-r--r-- | src/expr.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/expr.c b/src/expr.c index 795f65052..51a1f22a0 100644 --- a/src/expr.c +++ b/src/expr.c @@ -891,6 +891,15 @@ void sqlite3ExprSetHeightAndFlags(Parse *pParse, Expr *p){ #endif /* SQLITE_MAX_EXPR_DEPTH>0 */ /* +** Set the error offset for an Expr node, if possible. +*/ +void sqlite3ExprSetErrorOffset(Expr *pExpr, int iOfst){ + if( pExpr==0 ) return; + if( NEVER(ExprUseWJoin(pExpr)) ) return; + pExpr->w.iOfst = iOfst; +} + +/* ** This routine is the core allocator for Expr nodes. ** ** Construct a new expression node and return a pointer to it. Memory |