Difference between revisions of "Change the default schema/database."
From SQLZOO
(Created page with "Change the default schema/database. <div class='ht'> <div class=params>schema:gisq</div> <div> In many engines several independant databases may exist. Often each user has his...") |
|||
| (One intermediate revision by one user not shown) | |||
| Line 17: | Line 17: | ||
</source> | </source> | ||
<source lang='sql' class='def e-oracle'>ALTER SESSION SET CURRENT_SCHEMA = haggis | <source lang='sql' class='def e-oracle'>ALTER SESSION SET CURRENT_SCHEMA = haggis | ||
| − | <source lang='sql' class='def e-sqlserver'> | + | </source> |
| + | <source lang='sql' class='def e-sqlserver'>Use Master | ||
</source> | </source> | ||
<source lang='sql' class='def e-mysql'>USE scott | <source lang='sql' class='def e-mysql'>USE scott | ||
Latest revision as of 14:35, 17 July 2012
Change the default schema/database.
schema:gisq
In many engines several independant databases may exist. Often each user has his or her own database. This allows different users to use the same names for tables.
N/A. Access IS a single USER system.
\CONNECT template1 - scott
ALTER SESSION SET CURRENT_SCHEMA = haggis
USE MasterUSE scottChange the default schema/database.