Suggest a feature
×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: userc865b
Added: Jun 3, 2019 10:40 AM
Views: 5
Tags: php
makes fast questions in string with array_map and anonymous function
  1. $makeQuestions=function (){
  2.             return "?";
  3. };
  4. $sql = "SELECT * FROM tblTest WHERE testTable IN (".implode(',',array_map($makeQuestions,$parmsArray)).") AND year =?";