note 81859 added to function.extract

From: Date: Mon, 17 Mar 2008 02:19:36 +0000
Subject: note 81859 added to function.extract
Groups: php.notes 
Request: Send a blank email to php-notes+get-137113@lists.php.net to get a copy of this message
Re: anon at anon dot org, about extract() and null values Personally I've found use extracting multiple resultsets from db where the latter would overwrite the previous when a variable is not null ( and optionally if its not >0 ) It would be useful if $extract_type was extended on top of these two: EXTR_OVERWRITE EXTR_SKIP with something like this: EXTR_OVERWRITE_NULL - If there is a collision, overwrite the existing variable if it is null EXTR_OVERWRITE_0 - Same thing but == 0 or null EXTR_SKIP_NULL - If there is a collision, skip the new variable if the existing is not null EXTR_SKIP_0 - Same thing but == 0 or null Those ought to cover a few good cases that aren't covered now. ---- Server IP: 212.63.193.10 Probable Submitter: 85.229.97.52 ---- Manual Page -- http://www.php.net/manual/en/function.extract.php Edit -- https://master.php.net/note/edit/81859 Del: integrated -- https://master.php.net/note/delete/81859/integrated Del: useless -- https://master.php.net/note/delete/81859/useless Del: bad code -- https://master.php.net/note/delete/81859/bad+code Del: spam -- https://master.php.net/note/delete/81859/spam Del: non-english -- https://master.php.net/note/delete/81859/non-english Del: in docs -- https://master.php.net/note/delete/81859/in+docs Del: other reasons-- https://master.php.net/note/delete/81859 Reject -- https://master.php.net/note/reject/81859 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#137113) next »