SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 Data Corruption Issues
 Restore database
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/24/2009 :  06:49:48  Show Profile  Reply with Quote
Hello,

in my database with no data I am not able to make a backup. Because this isn't working and do want to start using it.

Now my question is what is the most easy way to create a new database with the same tables in it. I hope in this way that I can backup this new database, so I can start using it.

How can help me?

Thanks in advance,
Sven.

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 12/24/2009 :  07:51:37  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
What exactly do you mean by "I am not able to make a backup"? Is it giving an error (and if so which error)? How are you trying to backup?

You could use the generate script option from management studio (assuming this is 2005/2008). In Object explorer, right click the DB, tasks-generate scripts. It starts a wizard, just go through and select the objects to script.

--
Gail Shaw
SQL Server MVP
Go to Top of Page

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/24/2009 :  09:51:07  Show Profile  Reply with Quote
Hello,

this is the error message ...

TITLE: Microsoft SQL Server Management Studio Express
------------------------------

Backup failed for Server 'PPBE01-133\SQLEXPRESS'.
------------------------------
ADDITIONAL INFORMATION:

System.Data.SqlClient.SqlError: An error occurred while processing 'BackupMetadata' metadata for database id 5 file id 65537. (Microsoft.SqlServer.Express.Smo)

I am using SQL server 2005.

Best regards,
Sven.



Go to Top of Page

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 12/27/2009 :  08:13:23  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
Looks like the database might be damaged. Can you run this and post the results (run it in master, msdb and the DB that you can't backup)

DBCC CHECKDB (<Database Name>) WITH NO_INFOMSGS, ALL_ERRORMSGS


--
Gail Shaw
SQL Server MVP
Go to Top of Page

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/27/2009 :  10:33:08  Show Profile  Reply with Quote
Hello,

because it is an empty database, I script the database and restored it. Everything works fine again.

Thanks for the help.

Sven.
Go to Top of Page

webfred
Flowing Fount of Yak Knowledge

Germany
8679 Posts

Posted - 12/27/2009 :  12:11:18  Show Profile  Visit webfred's Homepage  Reply with Quote
But you should find out (if it is possible) the reason why your database was damaged.
Maybe it happens to your new created database again.


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/27/2009 :  12:29:25  Show Profile  Reply with Quote
Hello,

I am pretty sure it has gone wrong when I updated the database from SQL 2000 to SQL 2008.

When I run the command dbcc check db I get 2 lines where I can see that there are files offline. When I restored the database on SQL server 2008 with a script there where no errors anymore.

So I think everything is OK.

Do you agree? Or do you think I have to check some more issues?

Best regards,
Sven.
Go to Top of Page

webfred
Flowing Fount of Yak Knowledge

Germany
8679 Posts

Posted - 12/27/2009 :  12:45:32  Show Profile  Visit webfred's Homepage  Reply with Quote
OK, when you say RESTORE then you mean in this case you have CREATED the database with a script - right?
So now there is no other Server and no other version involved.

I agree and hope that everything is ok now and in the future.

Greetings
Fred



No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/27/2009 :  13:06:14  Show Profile  Reply with Quote
Hello,

indeed, I have created the database with a script.
I will regular make a backup and if I have some trouble I will come back to it.

Thank you for the help.

Sven.
Go to Top of Page

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 12/27/2009 :  15:50:50  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
quote:
Originally posted by sven2

When I run the command dbcc check db I get 2 lines where I can see that there are files offline.


Let me guess, full text? Means you didn't do the update from 2000 properly and left files behind. That's probably the reason for the backup failing. Hard to back up files that aren't there.

Without the actual messages it's hard to say anything more conclusive.

--
Gail Shaw
SQL Server MVP
Go to Top of Page

sven2
Yak Posting Veteran

Belgium
57 Posts

Posted - 12/28/2009 :  07:07:10  Show Profile  Reply with Quote
Hello,

indeed, the message full text was displayed.
But I solved it already with creating a new database by script.

Best regards,
Sven.
Go to Top of Page

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 12/28/2009 :  11:15:00  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
I meant 'full text indexing'.

--
Gail Shaw
SQL Server MVP
Go to Top of Page

tosscrosby
Aged Yak Warrior

USA
676 Posts

Posted - 12/28/2009 :  11:48:04  Show Profile  Reply with Quote
quote:
Originally posted by GilaMonster

I meant 'full text indexing'.

--
Gail Shaw
SQL Server MVP



What is the cost of recreating the full text indexing, if it was missed during the "upgrade"? Single user mode? Any idea how long it may take for a 2GB database?

Terry

-- Procrastinate now!
Go to Top of Page

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 12/28/2009 :  12:31:45  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
No idea, no idea and no idea. Sorry, am not an expert on FT. I've just seen upgrades of DBs with it, and know that there are ways to not attach/not upgrade the FT indexes.

--
Gail Shaw
SQL Server MVP
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.14 seconds. Powered By: Snitz Forums 2000