Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions code/go/example.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ package main
import (
"context"
"fmt"
"github.com/neo4j/neo4j-go-driver/v5/neo4j"
"reflect"

"github.com/neo4j/neo4j-go-driver/v6/neo4j"
)

func main() {
Expand All @@ -21,7 +22,7 @@ func main() {

func runQuery(uri, database, username, password string) (_ []string, err error) {
ctx := context.Background()
driver, err := neo4j.NewDriverWithContext(uri, neo4j.BasicAuth(username, password, ""))
driver, err := neo4j.NewDriver(uri, neo4j.BasicAuth(username, password, ""))
if err != nil {
return nil, err
}
Expand Down
5 changes: 3 additions & 2 deletions code/go/example_aura.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ package main
import (
"context"
"fmt"
"github.com/neo4j/neo4j-go-driver/v5/neo4j"

"github.com/neo4j/neo4j-go-driver/v6/neo4j"
)

func main() {
Expand All @@ -12,7 +13,7 @@ func main() {
// (You may need to replace your connection details, username and password)
uri := "neo4j+s://<Bolt url for Neo4j Aura database>"
auth := neo4j.BasicAuth("<Username for Neo4j Aura database>", "<Password for Neo4j Aura database>", "")
driver, err := neo4j.NewDriverWithContext(uri, auth)
driver, err := neo4j.NewDriver(uri, auth)
if err != nil {
panic(err)
}
Expand Down
4 changes: 2 additions & 2 deletions code/go/go.mod
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module example

go 1.20
go 1.24

require github.com/neo4j/neo4j-go-driver/v5 v5.8.0
require github.com/neo4j/neo4j-go-driver/v6 v6.0.0
4 changes: 2 additions & 2 deletions code/go/go.sum
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github.com/neo4j/neo4j-go-driver/v5 v5.8.0 h1:I+jtnFbbN9FvRP5etOsrdJNNEThHUCe6pO0MFk1md04=
github.com/neo4j/neo4j-go-driver/v5 v5.8.0/go.mod h1:Vff8OwT7QpLm7L2yYr85XNWe9Rbqlbeb9asNXJTHO4k=
github.com/neo4j/neo4j-go-driver/v6 v6.0.0 h1:xVAi6YLOfzXUx+1Lc/F2dUhpbN76BfKleZbAlnDFRiA=
github.com/neo4j/neo4j-go-driver/v6 v6.0.0/go.mod h1:hzSTfNfM31p1uRSzL1F/BAYOgaiTarE6OAQBajfsm+I=