<div dir="ltr"><div><div><div><div><div><div><div><div><div><div>Hi All,<br><br></div>This should be easy and I've done similar things before, but I can't seem to get the data structure to output properly. <br><br>
</div>I have data in the following format:<br><br></div>Market1 65000 3000<br></div>Market1 130000  5000<br></div>Market1 65000   4500<br></div>Market2 65000  3000<br></div>Market3 32000  800<br></div>Market3 32000  1000<br>
<br></div>What I need to do is get the markets so that they are unique so that I can use them as hash keys.  So I need to add all of the 2nd column and all of the 3rd column for each market so that there is only one entry per market, with the duplicate entries all added together.  <br>
<br>The data is coming out of an arrayref (from an Oracle database) so I don't have any code that shows the problem, just the foreach loop iterating through each reference in the arrayref.  <br><br>Any help would be greatly appreciated. <br>
<br>Thanks,<br><br></div>Lisa<br></div>