<commit_before><?php
/**
 * AMysql_Select 
 *
 * Anatomy of a select:
 * SELECT <SELECT OPTIONS> <COLUMNS> FROM <FROMS> <JOINS> <WHERES> <GROUP BYS> <HAVINGS>
 * <ORDER BYS> <LIMIT> <OFFSET>
 * 
 * Visit https://github.com/amcsi/amysql
 * @author      <NAME>
 * @license     MIT License; http://www.opensource.org/licenses/mit-license.php
 */
class AMysql_Select extends AMysql_Statement {

    protected $selectOptions = array ();
    protected $columnLiteral;
    protected $columns = array ();
    protected $froms = array ();
    protected $joins = array ();
    protected $wheres = array ();
    protected $groupBys = array ();
    protected $havings = array ();
    protected $orderBys = array ();
    protected $limit = null;
    protected $offset = null;

    /**
     * Adds a select option.
     *
     * e.g.
     * SQL_CALC_FOUND_ROWS
     * DISTINCT<commit_msg>Large description of AMysql_Select<commit_after><?php
/**
 * The class is for helping with the assembly of a mysqli SELECT string.
 * Rather than having to manually the string - especially of not only the values
 * of certain parameters would be dynamic, but the tables, columns, joins, wheres
 * and everything else is - you can get a new instance of this class by calling
 * $amyql->select(), and you can freely add fragments to the SELECT query with
 * the different methods of this class.
 * When you call ->execute(), the final, but unbound SQL string is automatically
 * prepared for binding with the passed (or pre-set) binds and execution.
 *
 * Since the bindings are applied after the SELECT sql string is assembled,
 * you are encouraged to use :named placeholders for WHEREs and anything similar,
 * binding the values with ->bindValue() each time, or collecting all the binds
 * to use in the end and passing it to ->execute().
 *
 * Please check @link tests/AMysql/SelectTest.php for examples.
 *
 * Anatomy of a select:
 * SELECT <SELECT OPTIONS> <COLUMNS> FROM <FROMS> <JOINS> <WHERES> <GROUP BYS> <HAVINGS>
 * <ORDER BYS> <LIMIT> <OFFSET>
 * 
 * Visit https://github.com/amcsi/amysql
 * @author      <NAME>
 * @license     MIT License; http://www.opensource.org/licenses/mit-license.php
 */
class AMysql_Select extends AMysql_Statement {

    protected $selectOptions = array ();
    protected $columnLiteral;
    protected $columns = array ();
    protected $froms = array ();
    protected $joins = array ();
    protected $wheres = array ();
    protected $groupBys = array ();
    protected $havings = array ();
    protected $orderBys = array ();
    protected $limit = null;
    protected $offset = null;

    /**
     * Adds a select option.
     *
     * e.g.
     * SQL_CALC_FOUND_ROWS
     * DISTINCT
{'fraction_non_alphanumeric': 0.1095890410958904, 'fraction_numerical': 0.0, 'mean_word_length': 3.241758241758242, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 29, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '608066', 'n_tokens_mistral': 812, 'n_tokens_neox': 788, 'n_words': 291}