mattn / go-oci8

Oracle driver for Go using database/sql
https://mattn.kaoriya.net/
MIT License
630 stars 212 forks source link

Connect string with Oracle wallet #329

Closed bop0hz closed 5 years ago

bop0hz commented 5 years ago

Hi,

I could not find how to connect with Oracle wallet. For example, I am able to connect in this way:

sqlplus /@tnsentry

Is it possible to connect with Oracle wallet credentials in go-oci8?

MichaelS11 commented 5 years ago

Looking at this:

https://docs.oracle.com/en/cloud/paas/atp-cloud/atpug/connect-preparing.html#GUID-3667EC68-930E-4566-95B3-DFA24203A8FF

I think it should work but do not have wallet setup to test. The connect string would be something like: username/password@tnsname_entry

MichaelS11 commented 5 years ago

@bop0hz Get this figured out? Can this be closed?

bop0hz commented 5 years ago

Actually not yet. I have no user/password with wallet. My connstring is mentioned above. I looked into the source code and there are no conditions to handle my case..

MichaelS11 commented 5 years ago

Or right, of course. Did you try just using the tnsnames entry? If so, what happens?

MichaelS11 commented 5 years ago

@bop0hz How did it go?

bop0hz commented 5 years ago

@bop0hz How did it go?

Sorry, Actually I have changed the oracle go driver to another. I will try it again with go-oci8 to get the error.

cjbj commented 5 years ago

@bop0hz out of interest, why did you decide to use go-oci8?

cjbj commented 5 years ago

Ignore me; too much github email and not enough coffee

bop0hz commented 5 years ago

Or right, of course. Did you try just using the tnsnames entry? If so, what happens?

ORA-01017: invalid username/password; logon denied

MichaelS11 commented 5 years ago

Is your sqlnet.ora file setup? What does it look like? Is your tnsnames.ora file setup? What does it look like?

MichaelS11 commented 5 years ago

@bop0hz Close this?

bop0hz commented 5 years ago

@bop0hz Close this?

ok, let's close..

MichaelS11 commented 5 years ago

If you would like to troubleshoot more, happy to help. Otherwise, can you please close it?