Closed
Description
Laravel Version
10.34.0
PHP Version
8.2
Database Driver & Version
MSSQL SERVER
Description
As part of 10.34 some change has been made that changes the behaviour of the
Schema::hasTable
method. In 10.33 and below this static function would return true for a view, allowing a view to be checked for existance before doing some code.
This behaviour has changed and now returns false for any view whether it exists or not.
I cant find the code that has made this change, but it may be related to #49020
There does not appear to be a replacement hasView method.
Mysql database seems to have always returned false.
Steps To Reproduce
- Create a view on a MSSQLSERVER database
- call Schema::hasTable('nameofview') and it will return false.
Downgrade to 10.33
- call Schema::hasTable('nameofview') and it will return true.