aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/printf.c7
-rw-r--r--src/treeview.c10
2 files changed, 3 insertions, 14 deletions
diff --git a/src/printf.c b/src/printf.c
index 58143e302..0fb3158e9 100644
--- a/src/printf.c
+++ b/src/printf.c
@@ -870,17 +870,14 @@ void sqlite3_str_vappendf(
}
if( pItem->zName ){
sqlite3_str_appendall(pAccum, pItem->zName);
- }else{
- sqlite3_str_append(pAccum, "(anonymous)", 11);
+ }else if( pItem->pSelect ){
+ sqlite3_str_appendf(pAccum, "SUBQUERY %u", pItem->pSelect->selId);
}
if( flag_altform2 ){
if( pItem->zAlias ){
sqlite3_str_append(pAccum, " AS ", 4);
sqlite3_str_appendall(pAccum, pItem->zAlias );
}
- if( pItem->pSelect ){
- sqlite3_str_appendf(pAccum, " SUBQUERY %u", pItem->pSelect->selId);
- }
}
length = width = 0;
break;
diff --git a/src/treeview.c b/src/treeview.c
index b696d764e..976558698 100644
--- a/src/treeview.c
+++ b/src/treeview.c
@@ -134,19 +134,11 @@ void sqlite3TreeViewSrcList(TreeView *pView, const SrcList *pSrc){
StrAccum x;
char zLine[100];
sqlite3StrAccumInit(&x, 0, zLine, sizeof(zLine), 0);
- sqlite3_str_appendf(&x, "{%d:*}", pItem->iCursor);
- if( pItem->zDatabase ){
- sqlite3_str_appendf(&x, " %s.%s", pItem->zDatabase, pItem->zName);
- }else if( pItem->zName ){
- sqlite3_str_appendf(&x, " %s", pItem->zName);
- }
+ sqlite3_str_appendf(&x, "{%d:*} %!S", pItem->iCursor, pItem);
if( pItem->pTab ){
sqlite3_str_appendf(&x, " tab=%Q nCol=%d ptr=%p used=%llx",
pItem->pTab->zName, pItem->pTab->nCol, pItem->pTab, pItem->colUsed);
}
- if( pItem->zAlias ){
- sqlite3_str_appendf(&x, " (AS %s)", pItem->zAlias);
- }
if( pItem->fg.jointype & JT_LEFT ){
sqlite3_str_appendf(&x, " LEFT-JOIN");
}