[Solved] Unique ID for year

The only way to be sure you have a unique Id in your data set is to test for it. $id = uniqid(2012); //returns a 13 character string plus it will append 2012 for 17 characters. $resultSet = //get dataSet from somewhere foreach($resultSet as $row) { if ($row[‘id’] = $id) { //do some stuff } … Read more