CohortExplorer::Command::Find - CohortExplorer class to find variables using keywords
find [OPTIONS] [KEYWORD]
f [OPTIONS] [KEYWORD]
This class is inherited from CLI::Framework::Command and overrides the following methods:
This method returns the usage information for the command.
( [ 'ignore-case|i' => 'ignore case' ], [ 'fuzzy|f' => 'fuzzy search' ], [ 'and|a' => 'Join keywords using AND (default OR)' ] )
Validates the command options and arguments and throws exception if validation fails.
This method enables the user to find variables using keywords. The command looks for the presence of keywords in columns specified in variable_structure method of the sub class. The command attempts to print the variable dictionary (i.e. meta data) of variables meeting the search criteria. The variable dictionary can include the following variable attributes:
variable name (mandatory)
table name (mandatory)
type (i.e. integer, decimal, date, datetime etc.)
unit
categories (if any) separated by newlines
label
Fuzzy search
Ignore case
Join keywords using AND (default OR)
This command throws the following exceptions imported from CLI::Framework::Exceptions:
throw_cmd_run_exception: This exception is thrown if one of the following conditions are met:
throw_cmd_run_exception
select method in SQL::Abstract::More fails to construct the SQL query from the supplied hash ref.
select
execute method in DBI fails to execute the SQL query.
execute
throw_cmd_validation_exception: This exception is thrown if the user has not supplied any arguments/keywords to the command. The command expects at least one keyword.
throw_cmd_validation_exception
CLI::Framework::Command
CLI::Framework::Exceptions
DBI
Exception::Class::TryCatch
SQL::Abstract::More
find --fuzzy --ignore-case cancer diabetes mmhg (fuzzy and case insensitive search) find Demographics (exact search) find -fia mmse total (using AND operation with bundling and aliases)
CohortExplorer
CohortExplorer::Datasource
CohortExplorer::Command::Describe
CohortExplorer::Command::History
CohortExplorer::Command::Query::Search
CohortExplorer::Command::Query::Compare
Copyright (c) 2013-2014 Abhishek Dixit (adixit@cpan.org). All rights reserved.
This program is free software: you can redistribute it and/or modify it under the terms of either:
the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version, or
the "Artistic Licence".
Abhishek Dixit
To install CohortExplorer, copy and paste the appropriate command in to your terminal.
cpanm
cpanm CohortExplorer
CPAN shell
perl -MCPAN -e shell install CohortExplorer
For more information on module installation, please visit the detailed CPAN module installation guide.