Originally Posted by
CTheSky
Hi, I have a problem about update table in a database. The situation is I have a table named member which store thousand rows of data records about thousand of member for a system. This member table has a field named MemberExpiryDate which used to store each member expired date. I have been asked to update the data records for member with member expired date equals to '2011/05/01'. So, as I count there are 50 of records (which member expired date is '2011/05/01') out of thousand of records in that member table need to be update. So, I write a Java program to update those 50 data records and the program is run without prompt out any error. But I have a question is how can I confirm that those 50 records out of thousand of records are updated completely and how can I confirm that other data except those 50 records are not affected and not updated ? Is it got any function in Java can let me know which record from those 50 records is not update exactly ? Is it got any method can let me know other data records except those 50 records are not affected ?
Thanks
It is not clear whether this updation requires any user input. I assume that your program has the values that are to be updated to these 50 records. Your problem is to find out how many rows are updated. There is no built in function for this as far as i know. you could place a counter in your program which will get incremented for each updates. You can easily tune this for getting the no. of rows that are not updated also.
Hope it answer your query. Cheers