Tnx
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4721 (20091228) __________
The message was checked by ESET NOD32 Antivirus.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Johnson" <Joh...@gmail.com> wrote in message
news:eA70Jp7h...@TK2MSFTNGP06.phx.gbl...
"Tibor Karaszi" <tibor_please.n...@hotmail.nomail.com> wrote in
message news:uOgnJKGi...@TK2MSFTNGP04.phx.gbl...
> signature database 4723 (20091228) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4723 (20091228) __________
A database snapshot will be transactionally consistent with the source
database therefore once a table/data is removed from the source database.
That said you can use SMO in the same way as any database to generate
scripts e.g.
the database MyAdventureworks
CREATE DATABASE [MyAdventureWorks] ON PRIMARY
( NAME = N'AdventureWorks_Data', FILENAME = N'C:\Program Files\Microsoft SQL
Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\MyAdventureWorks_Data.mdf' )
AS SNAPSHOT OF AdventureWorks
GO
The tables can be scripted out in Powershell and SMO using:
$s = new-object ('Microsoft.SqlServer.Management.Smo.Server') "LOCALHOST"
$dbs=$s.Databases
foreach ($tables in $dbs["MyAdventureworks"].Tables)
{
$outfile = "C:\Powershell\Examples\Output Scripts\" + $tables.name +
".sql"
$tables.Script() | out-File $outfile
}
If you want other scripts look at
http://www.mssqltips.com/tip.asp?tip=1842&home
John
We have only snapshot data file(.ss file). We dont have any connection info.
"John Bell" <jbellne...@hotmail.com> wrote in message
news:13DEDED2-7D72-484C...@microsoft.com...
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4725 (20091229) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4725 (20091229) __________
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Johnson" <Joh...@gmail.com> wrote in message
news:#tsYw7Ji...@TK2MSFTNGP04.phx.gbl...
Hi
To add to what Tibor has said.
Your .ss file is what was specified as the data file in the CREATE DATABASE
statement. It can not be detached or backed up, so without the instance
being stopped I would not be hopeful that even a normal mdf file would be
usable.
If you try to attach a copied file with sp_attach_single_file_db as
NewAdventureworks you will get an error:
Msg 3415, Level 16, State 3, Line 1
Database 'NewAdventureworks' cannot be upgraded because it is read-only or
has read-only files. Make the database or files writeable, and rerun
recovery.
Therefore it is pretty useless to you.
John
"John Bell" <jbellne...@hotmail.com> wrote in message
news:F8AF5D80-8D63-4820...@microsoft.com...
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4730 (20091230) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4730 (20091230) __________