man12_patil3 Posted June 26, 2010 Share Posted June 26, 2010 hi all, My prob. is that i am feacthing record from DB by while loop (Mysql fetch Arry) and print it row by row. id Begnning Stage Ending Stage Active 1 Begnner Intermidiate "No" 2 Intermidiate Uppper intermidiate "Yes" 3 Begnner Intermidiate "Yes" . . . . . . . . . . . . . . . . n . . . as above mention i want to Active is "NO" IF first Records Ending stage is same as next record "Begnning Stage". Link to comment https://forums.phpfreaks.com/topic/205933-how-to-change-provious-fetched-while-loop/ Share on other sites More sharing options...
bluejay002 Posted June 26, 2010 Share Posted June 26, 2010 You can do this in two ways: 1. Do this in your query. 2. Use a delayed printing of result by atleast 1 record and have the previous record stored in a temporary variable so that you can scan out what to do with it. My two cents. bluejay, Link to comment https://forums.phpfreaks.com/topic/205933-how-to-change-provious-fetched-while-loop/#findComment-1077604 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.