Groups | Blog | Home
all groups > sql server (alternate) > may 2006 >

sql server (alternate) : to read backup file


Zenek
5/20/2006 3:18:30 PM
Hello,


I have:
- server MS SQL MSDE (2000)
- database 'COLLBASE'
- table 'MAIN'
- row: column 'NAME' value 'version' and column 'VALUE' value '003'

I make backup files by SQL query.
I have more backups for different versions of this database (different
value in field 'VALUE' in table 'MAIN').

I would like to read this value from backup file without server assist,
to get backup as ordinary file.
How to do it?
How to move in this file?
What is physical structure of backup file?

I can't to read this file from begin by compare strings, because these
files are very large, few 100MB.

regards
Erland Sommarskog
5/20/2006 3:54:44 PM
Zenek (zingiel@op.pl) writes:
[quoted text, click to view]

What are you really trying to achieve? The normal way to read data from
a backup is to restore it into a database. And if the database is just a
mere couple of 100 MB, that's a fairly snap operation.


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
Erland Sommarskog
5/20/2006 11:10:11 PM
Zenek (zingiel@op.pl) writes:
[quoted text, click to view]

Please give a more detailed account of your actual problem. Particularly,
why is it not feasible to restore the backup and read the data?


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
Zenek
5/21/2006 12:27:57 AM
Erland Sommarskog napisa?(a):
[quoted text, click to view]
of course, but I need to know this value before restore, without server
assist.

Regards,
Zenek
5/21/2006 7:05:01 PM
Erland Sommarskog napisał(a):
[quoted text, click to view]
because I have my small program for several database's operations and I
want fast to view, fast to know versions of backups (to read value of
one field), I want not to use server or some libraries, I want to use
Erland Sommarskog
5/21/2006 10:15:56 PM
Zenek (zingiel@op.pl) writes:
[quoted text, click to view]

No, you don't want to that. The backup format is to my knowledge not
publicly documented.

If the databases are as small as you have indicated, there is little
loss in execution time in actually restoring the databases and reading
the value in the regular way.

And you did not really answer my question. That is, there must be some
real-world problem you are trying to solve. What does this value you want
to read represent?
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
AddThis Social Bookmark Button