This commit is contained in:
2026-05-01 23:40:14 +08:00
commit b8f599a617
3867 changed files with 478663 additions and 0 deletions
+40
View File
@@ -0,0 +1,40 @@
<?php
namespace Illuminate\Database\Schema;
use Illuminate\Support\Arr;
class SqlServerBuilder extends Builder
{
/**
* Drop all tables from the database.
*
* @return void
*/
public function dropAllTables()
{
$this->connection->statement($this->grammar->compileDropAllForeignKeys());
$this->connection->statement($this->grammar->compileDropAllTables());
}
/**
* Drop all views from the database.
*
* @return void
*/
public function dropAllViews()
{
$this->connection->statement($this->grammar->compileDropAllViews());
}
/**
* Get the default schema name for the connection.
*
* @return string|null
*/
public function getCurrentSchemaName()
{
return Arr::first($this->getSchemas(), fn ($schema) => $schema['default'])['name'];
}
}