mirror of
https://github.com/sqlite/sqlite.git
synced 2025-12-03 08:01:19 +03:00
Fix CREATE TABLE ... AS so that it works with column names that are empty
strings. FossilOrigin-Name: 632045f21c553e10f59a14c772d50d7824ca0c2c
This commit is contained in:
@@ -1452,10 +1452,10 @@ static void identPut(char *z, int *pIdx, char *zSignedIdent){
|
||||
for(j=0; zIdent[j]; j++){
|
||||
if( !sqlite3Isalnum(zIdent[j]) && zIdent[j]!='_' ) break;
|
||||
}
|
||||
needQuote = sqlite3Isdigit(zIdent[0]) || sqlite3KeywordCode(zIdent, j)!=TK_ID;
|
||||
if( !needQuote ){
|
||||
needQuote = zIdent[j];
|
||||
}
|
||||
needQuote = sqlite3Isdigit(zIdent[0])
|
||||
|| sqlite3KeywordCode(zIdent, j)!=TK_ID
|
||||
|| zIdent[j]!=0
|
||||
|| j==0;
|
||||
|
||||
if( needQuote ) z[i++] = '"';
|
||||
for(j=0; zIdent[j]; j++){
|
||||
|
||||
Reference in New Issue
Block a user