1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-14 00:22:38 +03:00

Make sure that integer values are converted to real when pulled from

a REAL table column by GROUP BY.  Ticket #2251.  Also make sure default
values are correctly expanded.  There may be other places in the code
where this issue comes up - we need to look further. (CVS 3659)

FossilOrigin-Name: e11bbf174c5a2fa75e3d1dd450c8b2a18f40e4da
This commit is contained in:
drh
2007-02-24 11:52:52 +00:00
parent 3e35580779
commit 945498f3f2
7 changed files with 86 additions and 37 deletions

View File

@@ -12,7 +12,7 @@
** This file contains C code routines that are called by the parser
** to handle SELECT statements in SQLite.
**
** $Id: select.c,v 1.327 2007/02/14 09:19:36 danielk1977 Exp $
** $Id: select.c,v 1.328 2007/02/24 11:52:54 drh Exp $
*/
#include "sqliteInt.h"
@@ -3144,13 +3144,7 @@ int sqlite3Select(
for(i=0; i<sAggInfo.nColumn; i++){
struct AggInfo_col *pCol = &sAggInfo.aCol[i];
if( pCol->iSorterColumn<j ) continue;
if( pCol->iColumn<0 ){
sqlite3VdbeAddOp(v, OP_Rowid, pCol->iTable, 0);
}else{
Table *pTab = pCol->pTab;
int op = (pTab && IsVirtual(pTab)) ? OP_VColumn : OP_Column;
sqlite3VdbeAddOp(v, op, pCol->iTable, pCol->iColumn);
}
sqlite3ExprCodeGetColumn(v, pCol->pTab, pCol->iColumn, pCol->iTable);
j++;
}
sqlite3VdbeAddOp(v, OP_MakeRecord, j, 0);