• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to sync the Host name and Service Name on the tnsnames.ora file using Java and JComboBox...

 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am having difficulty trying to get the tnsname.ora file to do the following:
1. I managed to get the JComboBox populated with the data from the service_name
2. My next question is the following:
a. How does one populate the CORRECT/appropriate host name (e.g. 127.0.0.3) if the specific service_name is selected on the JCombobox.
i. I know this can be done using a itemStateChanged(ItemEvent ie), and I can make it action so populates data whenever one selects a different service name. But the question is HOW or WHAT WAY can one do to do the following:
1. If the service_name equals a certain SID
a. Then go and get populate the textboxes which store:
i. Host
ii. Port
iii. Protocol

I have my own theory how this could be done but do not know how to translate this to Java code:
- If the service_name is selected
o Go to previous line (4 steps back) where host details is populated
 Populate the host data to the host textbox
o Go to the previous line where the port is populated
 Populate the port data to port textbox
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic