Browse Source

Merge branch 'dev/v1.0.18_wjh' into feature/v1.0.17

* dev/v1.0.18_wjh:
  xg
  xg
Jianghan 1 year ago
parent
commit
45ee1b1a8c
1 changed files with 3 additions and 1 deletions
  1. 3 1
      service/exprot.go

+ 3 - 1
service/exprot.go

@@ -283,7 +283,9 @@ func hName(sql string) []interface{} {
 	keystr := strings.ReplaceAll(s[0], "select", "")
 	keystr = strings.ReplaceAll(keystr, " ", "")
 	for _, s1 := range strings.Split(keystr, ",") {
-		key = append(key, strings.Split(s1, "as")[1])
+		if strings.Contains(s1, "as") {
+			key = append(key, strings.Split(s1, "as")[1])
+		}
 	}
 	return key
 }