Thanks Ramprasad - that works.
At 17:29 20/05/2004 +0530, Ramprasad A Padmanabhan wrote:
Wow,
unique items is surely an FAQ.
But here you dont need to filter the array, just see the answer inline
On Thu, 2004-05-20 at 17:07, Mark Martin wrote:
> Hi,
> I'm moving database data from table to table an
Ramprasad A Padmanabhan wrote:
>
> Wow,
> unique items is surely an FAQ.
> But here you dont need to filter the array, just see the answer inline
>
> On Thu, 2004-05-20 at 17:07, Mark Martin wrote:
> > Hi,
> > I'm moving database data from table to table and want to make sure I'm
> > getting only u
On May 20, Jeff 'japhy' Pinyan said:
> my (%count, %unique);
>
> while (my @row = $sth->fetchrow) {
>my $field = $row[0];
>if ($count{$field}++) { delete $unique{$field} }
>else { $unique{$field} = [ @row ] }; # or 1, or whatever you want
> }
>
>Here, every time a row is seen, its
On May 20, Mark Martin said:
>I'm moving database data from table to table and want to make sure I'm
>getting only unique records.
This is similar to a topic that came up two days ago.
>Only want unique $field1 and was looking at the cookbook code, but for that
>I have to populate a hash and the
Wow,
unique items is surely an FAQ.
But here you dont need to filter the array, just see the answer inline
On Thu, 2004-05-20 at 17:07, Mark Martin wrote:
> Hi,
> I'm moving database data from table to table and want to make sure I'm
> getting only unique records.
>
> Only want unique $field1 a
Hi,
I'm moving database data from table to table and want to make sure I'm
getting only unique records.
Only want unique $field1 and was looking at the cookbook code, but for that
I have to populate a hash and then re-inspect through before inserting
uniques, something like :
%ucnt = ();
while