Laravel php tinker command to show tables and structures? -
what command within laravels' php artisan tinker shows tables and/or structure of tables?
to tables, use this:
$tables = \db::select('show tables');
.
to columns of table, use this:
$columns = \schema::getcolumnlisting('<table_name>');
Comments
Post a Comment