use binary params

This commit is contained in:
Andre Medeiros 2021-07-05 21:12:09 -04:00
parent f2259ea5c1
commit 51c49193dd
2 changed files with 3 additions and 2 deletions

View file

@ -40,7 +40,7 @@ func main() {
dburl = os.Getenv("DATABASE_URL")
}
db, err := sql.Open("postgres", dburl)
db, err := sql.Open("postgres", fmt.Sprintf("%s?binary_parameters=yes", dburl))
if err != nil {
log.Fatal(err)
}

View file

@ -2,6 +2,7 @@ package main
import (
"database/sql"
"fmt"
"log"
"os"
"os/signal"
@ -129,7 +130,7 @@ func main() {
dburl = os.Getenv("DATABASE_URL")
}
db, err := sql.Open("postgres", dburl)
db, err := sql.Open("postgres", fmt.Sprintf("%s?binary_parameters=yes", dburl))
if err != nil {
log.Fatal(err)
}