فهرست منبع

Merge pull request #55 from coxx/master

Keyspace in USE statement enclosed in double quotation marks to make key space name case-sensitive
Christoph Hack 12 سال پیش
والد
کامیت
f1ad117797
2فایلهای تغییر یافته به همراه2 افزوده شده و 1 حذف شده
  1. 1 0
      AUTHORS
  2. 1 1
      conn.go

+ 1 - 0
AUTHORS

@@ -9,3 +9,4 @@ Niklas Korz <korz.niklask@gmail.com>
 Nimi Wariboko Jr <nimi@channelmeter.com>
 Ghais Issa <ghais.issa@gmail.com>
 Sasha Klizhentas <klizhentas@gmail.com>
+Konstantin Cherkasov <k.cherkasoff@gmail.com>

+ 1 - 1
conn.go

@@ -342,7 +342,7 @@ func (c *Conn) Address() string {
 }
 
 func (c *Conn) UseKeyspace(keyspace string) error {
-	resp, err := c.exec(&queryFrame{Stmt: "USE " + keyspace, Cons: Any}, nil)
+	resp, err := c.exec(&queryFrame{Stmt: `USE "` + keyspace + `"`, Cons: Any}, nil)
 	if err != nil {
 		return err
 	}