You can use textscan
to read the whole file, search for a keyword, extract the line found and then concatenate this line with the next line.
Here is an example, looking for Maria
fid = fopen('textfile.txt','r')
C = textscan(fid, '%s','Delimiter','');
fclose(fid)
C = C{:};
Lia = ~cellfun(@isempty, strfind(C,'Maria'));
output = [C{find(Lia)} ',' C{find(Lia)+1}]
which gives
Maria, female,24,married,born in USA