if i only enter 1 set of records i get a correct return but if i enter more than one set of record it only reconizes the last set. so when i search for student id the only one thats in the file that works correctly and displays the correct output is the last studentid entered rest dont work properly. basically its not starting at the first line of the file each search.
Your code doesn't make much sense to me.
You load the file into a vector but don't use to search.
Normally you should pass the vector to the search_data() function or are these two not related?.