Tell me more ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I am trying to query SharePoint list data from a database named like STS_bangbus_1 database, but there seem to be only one SQL Server instance with the named “bangbus” aka “SHAREPOINT”, with duplicated database file names in two different directories: C:\Program Files\Microsoft SQL Server\MSSQL$SHAREPOINT C:\Program Files\Microsoft SQL Server\MSSQL$SHAREPOINT\DATA

The latter is the default spot for the SharePoint list databases and has the much, much larger database file, likely with the current data. I suspect that someone made a backup copy in the parent directory (in Feb 2010?), which would be fine, except now we cannot query the AllList and AllUserData tables (in the lower directory) as we require.

Will deleting the backup database copy in the parent directory solve the issue? Can we delete these copies? If not, how can we query these two data tables to meet our requirements?

Any suggestions or advice would be most welcome.

PS It is an actual point in time copy of the mdf file in the parent directory. The working, active mdf in the child/default is not connected to the identically named database.

share|improve this question
I wouldn't delete anything until we straighten this out. When you say "backup database copy" what type of file are you talking about? .mdf/ndf/ldf ? Or .bak/trn/dif or something else? – Mike Walsh Dec 6 '12 at 3:07
Also when you say "we cannot query..." what do you mean? Errors? Missing database? Describe the problem a bit more, please. – Mike Walsh Dec 6 '12 at 3:08
We are querying the old copy of the database in the parent directory. – Todd O Dec 21 '12 at 22:49

migrated from stackoverflow.com Dec 6 '12 at 2:22

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.