Solved

VS 2008 -- ORACLE -- TNSNAMES Connection

Posted on 2009-07-13
3
569 Views
Last Modified: 2013-12-19
I created the below VS 2008 .net 3.5 Windows (non-web) Oracle APP, installed the .EXE on my machine accessing the remote DB and it worked.  I then upgraded my coworker's machine to .net 3.5, rebooted, installed the OracleClient, configured the TNSNAMES file to be the same as my file, installed the APP, and get the following error when running the app:

ORA-12514: TNS:listener could not resolve SERVICE_NAME given in connect descriptor

What else do I need to install or fix ?
---------------------------------------------------
Setup
 1. drop FMFORMULA gridView onto form
 2. drag FMENTITY gridView next to FMFORMULA
    gridView & delete FMENTITY gridView
     ** gets FMENTITY BindingSource
        and TableAdapter onto page
 3. edit FMFORMULA gridView COLUMNS
     ** FMENTITYID column
          a. READONLY = True
          b. ColumnType = ComboBox
          c. DataSource = fMENTITYBindingSource
          d. DisplayMember = FMENTITYNAME
          e. ValueMember = FMENTITYOBJECTID
          f. HeaderText = ENTITY
          g. DisplayStyle = Nothing
     ** FMCODE column
          a. READONLY = True
     ** FMVERSION column
          a. READONLY = keep "False"
     ** other columns
          a. Delete
 4. create gridView "DataError" EVENT
    messagebox ("Please enter numbers")
 5. add "order by FMCODE, FMENTITYID, FMVERSION"
    to DataSet1.xsd FMFORMULATableAdapter "FILL"
Adding Search
 6. rightClick DataSet1.xsd FMFORMULATableAdapter
      ** Add, Query, Select
      ** WHERE FMCODE = :FMCODE
           ** don't use "WHERE FMCODE = @FMCODE" like MSSQL uses
      ** add "order by FMCODE, FMENTITYID, FMVERSION"
         to DataSet1.xsd FMFORMULATableAdapter if needed
      ** Fill METHOD NAME = FillBy
      ** Return METHOD NAME = GetDataBy
 7. add below CONTROLS to existing Form1.cs "ToolStrip"
     ** Sepeartor
     ** Label
          a. TEXT = Search By Formula
     ** Textbox
          a. NAME = txt_FormulaCode
     ** Button
          a. DisplayStyle = Text
          b. Text = SUBMIT
          c. Click EVENT = toolStripButton1_Click
               ** this.fMFORMULATableAdapter.FillBy(this.dataSet1.FMFORMULA,this.txt_FormulaCode.Text);
     ** Button
          a. DisplayStyle = Text
          b. Text = CLEAR
          c. Click EVENT = toolStripButton2_Click
               ** this.fMFORMULATableAdapter.Fill(this.dataSet1.FMFORMULA);
 8. test by doing above "Summary" section, WORKS
0
Comment
Question by:finance_teacher
3 Comments
 
LVL 40

Expert Comment

by:mrjoltcola
ID: 24844378
From his machine, try tnsping <SERVICE NAME>

Your listener must be reachable from his PC.

Is there a firewall?
0
 

Author Comment

by:finance_teacher
ID: 24848927
Steps I did
 1. made sure .net 3.5 was working
 2. made sure "tnsping DB..." worked

What other things should I check ?
0
 
LVL 11

Accepted Solution

by:
it-rex earned 500 total points
ID: 24881451
we have hit this before looks like your VS config file is using a differnt service name than the one your are using ;
with tnsping you can use a ny valid service name you have chosen but with MS apps you need to make sure it is the smae like your config file.


0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
Background In several of the companies I have worked for, I noticed that corporate reporting is off loaded from the production database and done mainly on a clone database which needs to be kept up to date daily by various means, be it a logical…
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now