1. gary bloor
  2. PowerBuilder
  3. Tuesday, 19 March 2019 12:42 PM UTC

Hi I can connect to a database via SQL plus but not via PB ( get TNS could not resolve the connect identifier) I think I must be not entering the right things in the connection tab, but it only has an entry for server name.

So I have server name as placdev ( the database name not the hosting server)

Am I doing something wrong ?

Attached a screen shot of connecton tab This is what appears in the preview pain

// Profile placdev
SQLCA.DBMS = "O10 Oracle10g (10.1.0)"
SQLCA.LogPass = <******>
SQLCA.ServerName = "placdev"
SQLCA.LogId = "placar"
SQLCA.AutoCommit = False
SQLCA.DBParm = ""

 

This is the enery from the TNSNAME file

 

PLACDEV =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = havud217)(PORT = 1526))
    )
    (CONNECT_DATA =
      (SID = placdev)
    )

Attachments (1)
Olan Knight Accepted Answer Pending Moderation
  1. Tuesday, 19 March 2019 20:39 PM UTC
  2. PowerBuilder
  3. # 1

We make an effort to keep the Service Names all uppercase and all properly defined; i.e. no more than 8 characters in length.

Update the TNS entry:

PLACDEV =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = havud217)(PORT = 1526))
    )
    (CONNECT_DATA =
      (SID = PLACDEV)
    )

Update the code:

// Profile placdev
SQLCA.DBMS = "O10 Oracle10g (10.1.0)"
SQLCA.LogPass = <******>
SQLCA.ServerName = "PLACDEV"
SQLCA.LogId = "placar"
SQLCA.AutoCommit = False
SQLCA.DBParm = ""

 

See if that does the trick.

Olan

 

Comment
There are no comments made yet.
Bruce Armstrong Accepted Answer Pending Moderation
  1. Tuesday, 19 March 2019 14:35 PM UTC
  2. PowerBuilder
  3. # 2

That looks fine.  Are you sure you're using a 32 bit version of the Oracle client?  What error message are you getting?

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.