sql
This commit is contained in:
2
main.go
2
main.go
@@ -124,7 +124,7 @@ func loadDbEntries(ot string, id int64) map[string]metadataValues {
|
|||||||
log.Printf("Invalid object type: %s", ot)
|
log.Printf("Invalid object type: %s", ot)
|
||||||
return entries
|
return entries
|
||||||
}
|
}
|
||||||
rows,err:=db.Query("select meta_key, meta_value from ? where ? = ?", table, column, id)
|
rows,err:=db.Query("select meta_key, meta_value from $1 where $2 = $3", table, column, id)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Printf("db.Query: %s\n", err.Error())
|
log.Printf("db.Query: %s\n", err.Error())
|
||||||
return entries
|
return entries
|
||||||
|
Reference in New Issue
Block a user