
gmod_chado_fts_prep.pl - prepares a Chado schema to use full text searching

% gmod_chado_fts_prep.pl [--dbprofile (name)]

--dbprfile Specify a gmod.conf profile name (otherwise use default)

note about pg version note about all_feature_names materialized view

Scott Cain <scain@cpan.org>
Copyright (c) 2010
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

validate_prereqs()
Checks that the Pg version is OK and that all_feature_names is a table an not a view.
Nothing.
The DBI database handle for the database to be modified.
create_searchable_columns($dbh);
To modify existing feature, synonym and dbxref tables to add a "searchable" column for names and accessions.
Nothing.
The DBI database handle for the database to be modified.
create_search_triggers($dbh)
Creates database triggers on the searchable columns to keep them up to date.
Nothing.
The database handle, $dbh, for the database to be modified.
From Leighton's notes:
Add trigger function to each table to populate the searchable column when a data-modifying operation occurs on the target field.
This is made much easier by the existence of the tsvector_update_trigger() procedure.
create_all_feature_names($dbprof)
Creates the materialized view of all_feature_names, making sure to dematerialize it first. It does this by making system calls to the gmod_materialized_view_tool.pl script that comes with the Chado distribution.
Nothing.
The name of the Bio::GMOD::DB::Config profile.