gqt
gqt copied to clipboard
Can't seem to add namespace sql templates
Hey guys,
I'm really new to Golang so I'm sorry if this is a dumb question but I can't seem to get namespaces to work with gqt. If I just include the sql file directly then it works great. Here is a picture to show what I'm doing. Thanks!
- Nick
If you look at the top of the file, I can change it to
queries.Add("./sqltemplates/users","*.sql")
var Users = []User{}
userId := 1158
users, err2 := database.Query(queries.Get("find"),userId)
and that works just fine. Thanks!
Hey guys,
It's been a while since I've programmed in Go but I've started back up again and for some reason am having the same problem.. not sure what I'm doing wrong here. Here is a screenshot of what I'm attempting.