function drush_sql_cli

8.0.x sql.drush.inc drush_sql_cli()
6.x sql.drush.inc drush_sql_cli()
7.x sql.drush.inc drush_sql_cli()
3.x sql.drush.inc drush_sql_cli()
4.x sql.drush.inc drush_sql_cli()
5.x sql.drush.inc drush_sql_cli()
master sql.drush.inc drush_sql_cli()

File

commands/sql/sql.drush.inc, line 397
Drush sql commands

Code

function drush_sql_cli() {
  switch (_drush_sql_get_scheme()) {
    case 'mysql':
      $command = 'mysql ' . (drush_get_context('DRUSH_VERBOSE') ? ' -v' : '');
      $command .= _drush_sql_get_credentials();
      break;
    case 'pgsql':
      $command = ' psql';
      $command .= _drush_sql_get_credentials();
      break;
  }
  proc_close(proc_open($command, array(0 => STDIN, 1 => STDOUT, 2 => STDERR), $pipes));
}