Can we backup to Stream

  • Thread starter Thread starter ad
  • Start date Start date
A

ad

When we use the SQL to backup a database, we use:
backup database Health to disk='c:\Backup.bak' with init
This will generate a physical file in disk.

Can we backup file to a Stream?
 
When I use the asp.net to backup database, for example use
backup database Health to disk='c:\Backup.bak'
it will result in an error : No access right to c:\

So, I want to backup it up to a stream and download it to client.
 
Hi,

I don't think it is supported, however you might try one of these:
- backup to a temp folder and load it into stream
- use .net within sql server (2005) and do the magic there
 
I'd say find the cause of your permissions problem, rather than change the
architecture of your application for the worse.
 
I assume that you mean in other words, "make a service running at the
Administrator or system account that moves the file to a folder to which the
ASPNET account has rights to read from".

Cor
 
I forgot the ;-)

Cor

Cor Ligthert said:
I assume that you mean in other words, "make a service running at the
Administrator or system account that moves the file to a folder to which
the ASPNET account has rights to read from".

Cor
 
When we use the SQL to backup a database, we use:
backup database Health to disk='c:\Backup.bak' with init
This will generate a physical file in disk.

Can we backup file to a Stream?
And I repeat Scot M.'s.'s question in a modified manner. Why would you want to
let someone use a web site to backup a database??? Seems like an invitation for
someone to compromise the database. Just my opinion I could be wrong.
Good luck with your project,

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com
 
Back
Top