• Post Reply Bookmark Topic Watch Topic
  • New Topic

how to get a specific column from ResultSet? Help

Farhad Rahmati
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Guys

I know how to get a colum with JDBC and show it's data in JList or JTables.

But I want to query like (SELECT * FROM MYTABLE) and this table contains 15 columns.

I want to show only one column in JList and when you click on an Item in JList the relative data should be shown in other components like JTextFiels.

for example say customer table. has firstname, lastname, salary, ......

the JList should only show the last names. when you click on a customers last name, first name salary ............. should be shown in other components.

Can you Help? if Yes then Please

Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!