Roy Harvey
3/19/2007 2:08:00 PM
On Mon, 19 Mar 2007 08:52:15 -0500, "Mubashir Khan" <mubi@yahoo.com>
wrote:
>i always prefix my tables with the database name .....
>like ......
>Northwind..Authors
That is a good idea in scripts. It is a bad idea in a stored
procedure, view or trigger within the same database. In other words,
within the Northwind database no stored procedure, view or trigger
should use the Northwind qualifer. The problem this prevents is that
if a database is restored to another name, say with a _Temp suffix to
allow recovering some data, the stored procedure (or view or trigger)
in the _Temp copy will be referencing the original database, not
itself.
Roy Harvey
Beacon Falls, CT