Daoming,

Backup and admin scripts are not NH concerns.

What you CAN do is execute a SQL script like that using
session.CreateSQLQuery(...).ExecuteUpdate() or get the connection with
session.Connection and create your command from there.

   Diego


On Mon, Apr 5, 2010 at 14:13, Daoming Yang <[email protected]>wrote:

> Hi Everyone,
>
> I need to create a database back function for the normal user by using the
> web application.
>
> How can I run the following sample script in NHibernate or maybe you have a
> better solution to do the full database backup?
>
> BACKUP DATABASE [AdventureWorks] TO
>       DISK = 
> N'\\nas\Backup\L40\SQL2005\AdventureWorks_backup_200702120215.bak'
>       WITH NOFORMAT, NOINIT,  NAME = N'AdventureWorks-Full Database Backup',
>       SKIP, NOREWIND, NOUNLOAD,  STATS = 10
>
>
>
> Thank you very much.
>
> Daoming
>
> --
> You received this message because you are subscribed to the Google Groups
> "nhusers" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<nhusers%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/nhusers?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to