Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to find the column count in resultset?



How to find the column count in resultset?..

Answer / babu h m

We need to use MetaData option on the ResultSet in order to
get the column count

ResultSet xSet = stmt.executeQuery() ;
ResultSetMetaData rsMetaData = xSet.getMetaData() ;
int numOfColumns = rsMetaData.getColumnCount() ;

Is This Answer Correct ?    12 Yes 2 No

Post New Answer

More JDBC Interview Questions

What is jdbc connection interface?

0 Answers  


What is jdbc and jpa?

0 Answers  


Can the JDBC-ODBC Bridge be used with applets?

2 Answers  


What is odbc. how is it related to sql cli?

0 Answers  


What protocol does jdbc use?

0 Answers  


While in CallableStatament using in the oracle my procedure is return no.of columns so in java how can i retrivbe the data and i wnat to view all data which is reetrive from my procedure

0 Answers   ADP,


is java pure object oriented or not ?

7 Answers  


What does jdbc setmaxrows method do?

0 Answers  


how to use CallableStatement? specially how to use their index given ..

1 Answers  


What is a statement in java?

0 Answers  


Describe odbc?

0 Answers  


What are 4 drivers available in JDBC? At what situation are four of the drivers used?

0 Answers  


Categories