cooldude832 Posted July 22, 2007 Share Posted July 22, 2007 I think the title says it, but I'm wondering if i'm only using an associative key should i just use assoc or is the speed so minimal it don't matter? Link to comment https://forums.phpfreaks.com/topic/61246-which-fetch-is-the-fastest-mysql_fetch_-arrayassoc-or-another/ Share on other sites More sharing options...
trq Posted July 22, 2007 Share Posted July 22, 2007 If your accessing your array elements via associative keys it is slightly more efficient to use mysql_fetch_assoc as mysql_fetch_array retrieves both numeric and associative by default. The difference would be VERY minimal though. Link to comment https://forums.phpfreaks.com/topic/61246-which-fetch-is-the-fastest-mysql_fetch_-arrayassoc-or-another/#findComment-304724 Share on other sites More sharing options...
Barand Posted July 22, 2007 Share Posted July 22, 2007 fetch_row is fastest, but again it's minimal Link to comment https://forums.phpfreaks.com/topic/61246-which-fetch-is-the-fastest-mysql_fetch_-arrayassoc-or-another/#findComment-304744 Share on other sites More sharing options...
cooldude832 Posted July 22, 2007 Author Share Posted July 22, 2007 yeah, but if you have 50+ fields it might make a difference Link to comment https://forums.phpfreaks.com/topic/61246-which-fetch-is-the-fastest-mysql_fetch_-arrayassoc-or-another/#findComment-304750 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.