#!/usr/bin/perl
use FTNDB;
FTNDB->run;

=head1 NAME

ftndbadm - Administration of an SQL database for Fidonet/FTN processing.

=head1 VERSION

Version 0.30

=cut

our $VERSION = '0.30';

=head1 DESCRIPTION

Administration of a database for Fidonet/FTN related processing. The SQL
database engine is one for which a DBD module exists, defaulting to SQLite.

=head1 SYNOPSIS

C<ftndbadm -c config_file [options] create|drop database name>

C<ftndbadm -c config_file [options] create|drop table name>

C<ftndbadm [-h | --help]>

C<ftndbadm --version>

=head1 OPTIONS

=over

=item -c

This is the filename and path of a configuration file, with the
default being ftndb.cfg in the current directory.

=item -x

Debug option.

=item -v

Verbose option.

=back

=head1 COMMANDS

=over

=item create database name

This will create a database an SQL database server being used
for Fidonet/FTN processing, where I<name> is the name of the
database to be created. If it already exists, it will drop
it first, before going on to create it again.

=item drop database name

This will drop a database if it exists in an SQL database server
being used for Fidonet/FTN processing, where I<name> is the name
of the database to be dropped.

=item create table name

This will create a nodelist table in an SQL database being used
for Fidonet/FTN nodelist processing, where I<name> is the name
of the table to be created. If it already exists, it will be
dropped it first before going on to create it again.

=item drop table name

This will drop a database table if it exists in an SQL database
server being used for Fidonet/FTN processing, where I<name> is
the name of the table to be dropped.

=back


=head1 CONFIGURATION

See L<FTNDB::Config> for details regarding configuration of
the application.


=head1 EXAMPLES

Given that $CFGFILE is a configuration file, the following command line can be
used to create an FTN Nodelist table in that database file:

C<ftndbadm -c $CFGFILE -v create table Nodelist> 

=head1 AUTHOR

Robert James Clay, C<< <jame at rocasa.us> >>

=head1 BUGS

Please report any bugs or feature requests via the web interface at
L<https://sourceforge.net/p/ftnpl/ftndb/tickets/>. I will be notified,
and then you'll automatically be notified of progress on your bug
as I make changes.

Note that you can also report any bugs or feature requests to
C<bug-ftn-database at rt.cpan.org>, or through the web interface at
L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=FTN-Database>;
however, the FTN-Database Issue tracker is preferred.


=head1 SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc ftndbadm


You can also look for information at:

=over 4

=item * FTN-Database issue tracker

L<https://sourceforge.net/p/ftnpl/ftndb/tickets/>

=item * RT: CPAN's request tracker

L<http://rt.cpan.org/NoAuth/Bugs.html?Dist=FTN-Database>

=item * Search CPAN

L<http://search.cpan.org/dist/FTN-Database>

=back

=head1 SEE ALSO

 L<ftndbadm>, L<ftndb-admim>, L<ftndb-nodelist>, L<FTNDB>, L<FTNDB::Command::create>,
  L<FTNDB::Command::drop>, L<FTN::Database>, L<FTN::Database::Nodelist>

=head1 COPYRIGHT & LICENSE

Copyright 2012 Robert James Clay, all rights reserved.

This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.

=cut

