PHP Classes

File: src/SQLTools/Command/RenameTable.php

Recommend this page to a friend!
  Classes of Rafael Lúcio   SQLTools   src/SQLTools/Command/RenameTable.php   Download  
File: src/SQLTools/Command/RenameTable.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: SQLTools
Create and alter databases, tables and indexes
Author: By
Last change: Update of src/SQLTools/Command/RenameTable.php
Date: 6 months ago
Size: 467 bytes
 

Contents

Class file image Download
<?php

namespace SQLTools\Command;


use
SQLTools\Base\ICommand;

class
RenameTable implements ICommand {

   
/**
     * Old table name
     * @var string
     */
   
private $old;
   
/**
     * New table name
     * @var string
     */
   
private $new;

    public function
__construct($old, $new)
    {
       
$this->old = $old;
       
$this->new = $new;
    }

    public function
getSql()
    {
        return
"RENAME {$this->old} TO {$this->new};";
    }

}