+ my $dbh = C4::Context->dbh;
+ if ($catcode){
+ my $sth =
+ $dbh->prepare(
+ "SELECT description,dateofbirthrequired,upperagelimit,category_type
+ FROM categories
+ WHERE categorycode = ?"
+ );
+ $sth->execute($catcode);
+ my $data =
+ $sth->fetchrow_hashref;
+ $sth->finish();
+ return $data;
+ }
+ return;
+} # sub getborrowercategory
+
+=head2 GetBorrowercategoryList
+
+ $arrayref_hashref = &GetBorrowercategoryList;
+If no category code provided, the function returns all the categories.
+
+=cut
+
+sub GetBorrowercategoryList {