Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old January 25th, 2008, 06:57 AM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2007
Location: , , .
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default Files in use

Hello,

I am new to a system and there are a lot files in a SQL database, most of these files are empty. Because I am only interested in files that contain records I would like to know if there is a tool that gives an overview of all the files and their properties (like numer of records) in a SQL server database.

Many thanks in advance,

John
  #2 (permalink)  
Old January 26th, 2008, 01:48 PM
Friend of Wrox
 
Join Date: Oct 2007
Location: , , .
Posts: 130
Thanks: 0
Thanked 3 Times in 3 Posts
Send a message via AIM to urtrivedi
Default

By default there are two files associated with sql database
.mdf and .ldf

you can find this files in program files/mssql/........../data
folder
if you want to keep copy of that file than stop sql service and then copy files
also you can use attach,detach database procedures

urt
  #3 (permalink)  
Old January 26th, 2008, 08:44 PM
Friend of Wrox
Points: 1,536, Level: 15
Points: 1,536, Level: 15 Points: 1,536, Level: 15 Points: 1,536, Level: 15
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2006
Location: , MI, USA.
Posts: 475
Thanks: 0
Thanked 9 Times in 9 Posts
Default

 
Quote:
quote:I am new to a system and there are a lot files in a SQL database, most of these files are empty


Um.... no... there are two files per database as a default and I guarantee that none of them are empty even when first created.

What do you mean by "files"???

--Jeff Moden
  #4 (permalink)  
Old January 28th, 2008, 05:05 AM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2007
Location: , , .
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default


With files I mean tables, (I come from I-series system where files and members are the terms in use).

My question remains: is there a tool that gives an overview of all the tables and their properties (like numer of records) in a SQL server database.
Many thanks in advance,

John
  #5 (permalink)  
Old January 28th, 2008, 04:42 PM
Friend of Wrox
Points: 1,536, Level: 15
Points: 1,536, Level: 15 Points: 1,536, Level: 15 Points: 1,536, Level: 15
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2006
Location: , MI, USA.
Posts: 475
Thanks: 0
Thanked 9 Times in 9 Posts
Default

Yes... and a bit more, as well... takes a bit to run but if you direct the output to a table or a spreadsheet, had lot's of useful info...

DBCC SHOWCONTIG WITH TABLERESULTS

--Jeff Moden
  #6 (permalink)  
Old January 31st, 2008, 04:48 AM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2007
Location: , , .
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you very much Jeff Moden!

Regards,

John


Similar Threads
Thread Thread Starter Forum Replies Last Post
Generating Excel FIles from resource Files abinashpatra ASP.NET 1.0 and 1.1 Basics 0 July 28th, 2008 02:07 AM
compare 2 files and output third files mtnguye6 VBScript 0 April 14th, 2008 11:03 AM
.php files vs .html files pbuongiovanni PHP How-To 2 January 5th, 2006 04:15 AM
decrypt files from zip files mmmobasher VS.NET 2002/2003 0 January 21st, 2004 03:19 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.