Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2013
    Posts
    14

    Unanswered: Database link access issue in plsql block

    Hello,

    I have created a database link as follows
    create public database link HWPROD
    connect to HW_REVIEWDB
    identified by "xxxxxxx"
    using '(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP )(HOST=rb-engsrv36n.xx.xx.com)(PORT=3800)))(CONNECT_DATA=(si d=xxx152)))';

    Database link is created successfully. When issues a sql statement like
    select * from dual@HWPROD is works fine.
    But when the same is used in PLSQL block it throws error "illegal database charater '-'". This is due to HOST=rb-engsrv36n.xx.xx.com.

    It is not possible to change the host name or update the global name of the database as described in this link (Many instances are present on the server)
    https://community.oracle.com/message/4398257.

    Could you let me know if there is another work around for this issue?

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >Could you let me know if there is another work around for this issue?

    a) use double quote marks, CHR(34); as follows (HOST="rb-engsrv36n.xx.xx.com"), which may introduce CaSe Problem.
    b) create new DNS entry which would essentially be an alias name to resolve to same IP#
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •