SilverStripe\Sakemore\Commands\SQLConsoleRole
Provides shell access to the database used by the site.
Synopsis
class SQLConsoleRole
extends DataExtension
{
- // constants
- const CMD_SQLCONSOLE = 'sql';
- // methods
- public void commands()
- public void help_brief()
- public void help_parameters()
- public void help_examples()
- public void startConsole()
- protected void getDatabaseCommand()
Hierarchy
Extends
- DataExtension
Tasks
Line | Task |
---|---|
32 | Add in which environment to use. |
Constants
Name | Value |
---|---|
CMD_SQLCONSOLE | 'sql' |
Methods
protected
- getDatabaseCommand() — Gets the current database details for the current environment.
public
- commands() — Tell sake more about this command.
- help_brief() — Gives sake a brief for the help section.
- help_examples() — Gives sake a list of examples of how to use this command.
- help_parameters() — Gives sake a list of the parameters used.
- startConsole() — Attempts to start a SQL console.