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...

i have 1000 records in resultset, how to get first 100
records from resultset, because resultset fetch all 1000
records at a time?

Answer Posted / sumit

The question is not pretty clear. However, before retriving the records from the database if you want to make sure you get only 100 records in one hit. U can use the following API after creating the statement object.

Statement.setFetchSize(100);

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a datasource in java?

956


Can we have foreign key reference to a non primary key column ?

985


What is meant by dao?

939


Why hibernate is better than jdbc?

935


What does jdbc setmaxrows method do?

967


What are the benefits of PreparedStatement over Statement?

1010


Explain about DSN?

975


Explain different types of locks in jdbc?

945


What are clob and blob data types in jdbc?

1040


What does setautocommit do?

971


How vendor Naming registry supports JNDI?

2205


What is addbatch jdbc?

1043


How to move the cursor in scrollable resultset ?

1037


Why would you use setautocommit(false) in jdbc?

1206


What is JDBC RowSet? What are different types of RowSet?

1095