Code Duplication    Length = 9-9 lines in 2 locations

src/Query/Dialects/MySQL/CreateTable.php 1 location

@@ 39-47 (lines=9) @@
36
		$sql .= $this->ifNotExists ? 'IF NOT EXISTS ' : '';
37
		$sql .= $this->quote($this->name);
38
39
		if(!empty($this->cols)){
40
			$sql .= ' ('.PHP_EOL."\t".implode(','.PHP_EOL."\t", $this->cols);
41
42
			if($this->primaryKey){
43
				$sql .=','.PHP_EOL."\t".'PRIMARY KEY ('.$this->quote($this->primaryKey).')';
44
			}
45
46
			$sql .= PHP_EOL.')';
47
		}
48
49
		if(!empty($this->collate)){
50
			list($charset) = explode('_', $this->collate);

src/Query/Dialects/Postgres/CreateTable.php 1 location

@@ 42-50 (lines=9) @@
39
40
		$sql .= $this->quote($n[count($n)-1]);
41
42
		if(!empty($this->cols)){
43
			$sql .= ' ('.PHP_EOL."\t".implode(','.PHP_EOL."\t", $this->cols);
44
45
			if($this->primaryKey){
46
				$sql .=','.PHP_EOL."\t".'PRIMARY KEY ('.$this->quote($this->primaryKey).')';
47
			}
48
49
			$sql .= PHP_EOL.')';
50
		}
51
52
		$sql .= '';
53