#!/usr/bin/perl use strict; use lib './'; use Links qw/$IN $DB $CFG/; use CGI::Carp qw(fatalsToBrowser); local $SIG{__DIE__} = \&Links::fatal; Links::init('./'); my $table = $DB->table('Category'); my $sth = $table->select(); while (my $hit = $sth->fetchrow_hashref) { my $full_name = $hit->{Full_Name}; my $name = $hit->{Name}; $full_name =~ s/_\// /ig; my $meta_description = qq|The global search engine - $full_name|; my @meta_keywords = split / / , $full_name; my $meta_keywords = join(",",@meta_keywords); $DB->table('Category')->update( { Meta_Keywords => lc($meta_keywords), Meta_Description => $meta_description }, { ID => $hit->{ID} } ); print ".... UPDATED ......"; }