Find records#

Extracts documents from the databaase containing the text string specified by the parameter search_for in the column specified by the parameter field. This functions allows the use of regular expressions for searching. The report is saved to the file reports/find_records.txt.

>>> from techminer2.search import find_records
>>> root_dir = "data/regtech/"
>>> find_records(
...     #
...     # SEARCH PARAMS:
...     field='author_keywords',
...     search_for='REGTECH',
...     case=False,
...     flags=0,
...     regex=True,
...     report_filename="find_records.txt",
...     #
...     # DATABASE PARAMS:
...     root_dir="example/",
...     database="main",
...     year_filter=None,
...     cited_by_filter=None,
... )
--INFO-- The file 'example/reports/find_records.txt' was created.
>>> find_records(
...     #
...     # SEARCH PARAMS:
...     field='abstract',
...     search_for='five-year',
...     case=False,
...     flags=0,
...     regex=True,
...     report_filename="find_records.txt",
...     #
...     # DATABASE PARAMS:
...     root_dir="example/",
...     database="main",
...     year_filter=None,
...     cited_by_filter=None,
... )
--INFO-- The file 'example/reports/find_records.txt' was created.
>>> find_records(
...     #
...     # SEARCH PARAMS:
...     field='abstract',
...     search_for='anti',
...     case=False,
...     flags=0,
...     regex=True,
...     report_filename="find_records.txt",
...     #
...     # DATABASE PARAMS:
...     root_dir="example/",
...     database="main",
...     year_filter=None,
...     cited_by_filter=None,
... )
--INFO-- The file 'example/reports/find_records.txt' was created.