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
2 changes: 1 addition & 1 deletion contrib/godror/usql-config
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
DB="godror://system:P4ssw0rd@localhost/orasid"
VSQL="SELECT version FROM v\$instance"
VSQL="SELECT banner as version FROM v\$version"
2 changes: 1 addition & 1 deletion contrib/oracle-enterprise/usql-config
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
DB="oracle://system:P4ssw0rd@localhost:1522/db1"
VSQL="SELECT version FROM v\$instance"
VSQL="SELECT banner as version FROM v\$version"
2 changes: 1 addition & 1 deletion contrib/oracle/usql-config
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
DB="oracle://system:P4ssw0rd@localhost/free"
VSQL="SELECT version FROM v\$instance"
VSQL="SELECT banner as version FROM v\$version"
4 changes: 2 additions & 2 deletions drivers/oracle/orshared/orshared.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ func Register(name string, err func(error) (string, string), isPasswordErr func(
},
Version: func(ctx context.Context, db drivers.DB) (string, error) {
var ver string
if err := db.QueryRowContext(ctx, `SELECT version FROM v$instance`).Scan(&ver); err != nil {
if err := db.QueryRowContext(ctx, `SELECT banner FROM v$version`).Scan(&ver); err != nil {
return "", err
}
return "Oracle Database " + ver, nil
return ver, nil
},
User: func(ctx context.Context, db drivers.DB) (string, error) {
var user string
Expand Down
Loading