Further corner-case fixes to the name resolution logic.

FossilOrigin-Name: 20730bad7082b559a65e8cfedb31b6afca50df58
diff --git a/src/resolve.c b/src/resolve.c
index b9f5123..944fb5c 100644
--- a/src/resolve.c
+++ b/src/resolve.c
@@ -271,6 +271,7 @@
               cntTab = 2;
               pMatch = pItem;
               pExpr->iColumn = j;
+              hit = 1;
             }
           }
           if( hit || zTab==0 ) continue;