Showing posts with label drive. Show all posts
Showing posts with label drive. Show all posts

Sunday, February 26, 2012

Help SQL server 7 dump data to hard drive

Hi,

I am running sql server 7 with 200+GB database size. I have one table with following fields

IIINDEX
DOCTYPE
IMAGE BLOB

I need to dump all the information from this table to hard drive.

I have try with delphi ado and delphi odbc (limit 1mb), somehow when I run the program it gives me an error message E_ timeout.

How can I dump this information without using delphi.

Any help will be highly appreciated.

If you have any code that can help please email me samirp@.ix.netcom.com

Thanks.

Samirtry using bcp ... might work .. though havent tried it with Image data.

Friday, February 24, 2012

Help selecting Veritas products

I have two Windows Server 2003 servers. One is a domain controller and the
other has SQL Server. The tape drive is in the domain controller. Am I OK
with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
for Windows Server?
ThanksHi
You could back up your database to disc (a network resource) and then you
would not need the remote agent.
John
"r042wal" wrote:
> I have two Windows Server 2003 servers. One is a domain controller and the
> other has SQL Server. The tape drive is in the domain controller. Am I OK
> with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
> for Windows Server?
> Thanks
>
>|||r042wal wrote:
> I have two Windows Server 2003 servers. One is a domain controller and the
> other has SQL Server. The tape drive is in the domain controller. Am I OK
> with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
> for Windows Server?
> Thanks
>
Don't use a backup agent to do SQL backups, they tend to be problematic
at best, and take longer to backup than a "normal" SQL backup. Just use
the SQL command BACKUP to dump the database contents to a disk file,
then backup that disk file using your tape backup software.
Tracy McKibben
MCDBA
http://www.realsqlguy.com|||Tracy, can the backup command in SQL be automated? I want to do a scheduled
backup nightly.
Thanks
"Tracy McKibben" <tracy@.realsqlguy.com> wrote in message
news:uXSKJRmuGHA.3392@.TK2MSFTNGP04.phx.gbl...
> r042wal wrote:
>> I have two Windows Server 2003 servers. One is a domain controller and
>> the other has SQL Server. The tape drive is in the domain controller.
>> Am I OK with Backup Exec 10d for Windows Servers and a remote agent for
>> SQL Server for Windows Server?
>> Thanks
> Don't use a backup agent to do SQL backups, they tend to be problematic at
> best, and take longer to backup than a "normal" SQL backup. Just use the
> SQL command BACKUP to dump the database contents to a disk file, then
> backup that disk file using your tape backup software.
>
> --
> Tracy McKibben
> MCDBA
> http://www.realsqlguy.com|||Hi
If you right click the database in the treeview of Enterprise Manager and
choose the backup option, then at the bottom of the general tab is an option
to schedule the backup. Alternatively you can look at using a maintenance
plan which will also allow you to schedule tasks for multiple databases and
allows you to do other things like index reorganization. To create a new
maintenance plan check out the Management branch, right click Database
Maintenance Plans and choose New Maintenance Plan.
John
"r042wal" wrote:
> Tracy, can the backup command in SQL be automated? I want to do a scheduled
> backup nightly.
> Thanks
> "Tracy McKibben" <tracy@.realsqlguy.com> wrote in message
> news:uXSKJRmuGHA.3392@.TK2MSFTNGP04.phx.gbl...
> > r042wal wrote:
> >> I have two Windows Server 2003 servers. One is a domain controller and
> >> the other has SQL Server. The tape drive is in the domain controller.
> >> Am I OK with Backup Exec 10d for Windows Servers and a remote agent for
> >> SQL Server for Windows Server?
> >>
> >> Thanks
> >
> > Don't use a backup agent to do SQL backups, they tend to be problematic at
> > best, and take longer to backup than a "normal" SQL backup. Just use the
> > SQL command BACKUP to dump the database contents to a disk file, then
> > backup that disk file using your tape backup software.
> >
> >
> >
> > --
> > Tracy McKibben
> > MCDBA
> > http://www.realsqlguy.com
>
>|||r042wal wrote:
> Tracy, can the backup command in SQL be automated? I want to do a scheduled
> backup nightly.
>
Absolutely, just setup a job in SQL Agent that runs the necessary BACKUP
command(s). You might also have a look at a script I've written that I
use to do backups:
http://realsqlguy.com/twiki/bin/view/RealSQLGuy/AutomaticBackupOfAllDatabases
Tracy McKibben
MCDBA
http://www.realsqlguy.com

Help selecting Veritas products

I have two Windows Server 2003 servers. One is a domain controller and the
other has SQL Server. The tape drive is in the domain controller. Am I OK
with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
for Windows Server?
ThanksHi
You could back up your database to disc (a network resource) and then you
would not need the remote agent.
John
"r042wal" wrote:

> I have two Windows Server 2003 servers. One is a domain controller and th
e
> other has SQL Server. The tape drive is in the domain controller. Am I O
K
> with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
> for Windows Server?
> Thanks
>
>|||r042wal wrote:
> I have two Windows Server 2003 servers. One is a domain controller and th
e
> other has SQL Server. The tape drive is in the domain controller. Am I O
K
> with Backup Exec 10d for Windows Servers and a remote agent for SQL Server
> for Windows Server?
> Thanks
>
Don't use a backup agent to do SQL backups, they tend to be problematic
at best, and take longer to backup than a "normal" SQL backup. Just use
the SQL command BACKUP to dump the database contents to a disk file,
then backup that disk file using your tape backup software.
Tracy McKibben
MCDBA
http://www.realsqlguy.com|||Tracy, can the backup command in SQL be automated? I want to do a scheduled
backup nightly.
Thanks
"Tracy McKibben" <tracy@.realsqlguy.com> wrote in message
news:uXSKJRmuGHA.3392@.TK2MSFTNGP04.phx.gbl...
> r042wal wrote:
> Don't use a backup agent to do SQL backups, they tend to be problematic at
> best, and take longer to backup than a "normal" SQL backup. Just use the
> SQL command BACKUP to dump the database contents to a disk file, then
> backup that disk file using your tape backup software.
>
> --
> Tracy McKibben
> MCDBA
> http://www.realsqlguy.com|||Hi
If you right click the database in the treeview of Enterprise Manager and
choose the backup option, then at the bottom of the general tab is an option
to schedule the backup. Alternatively you can look at using a maintenance
plan which will also allow you to schedule tasks for multiple databases and
allows you to do other things like index reorganization. To create a new
maintenance plan check out the Management branch, right click Database
Maintenance Plans and choose New Maintenance Plan.
John
"r042wal" wrote:

> Tracy, can the backup command in SQL be automated? I want to do a schedul
ed
> backup nightly.
> Thanks
> "Tracy McKibben" <tracy@.realsqlguy.com> wrote in message
> news:uXSKJRmuGHA.3392@.TK2MSFTNGP04.phx.gbl...
>
>|||r042wal wrote:
> Tracy, can the backup command in SQL be automated? I want to do a schedul
ed
> backup nightly.
>
Absolutely, just setup a job in SQL Agent that runs the necessary BACKUP
command(s). You might also have a look at a script I've written that I
use to do backups:
http://realsqlguy.com/twiki/bin/vie...realsqlguy.com

Help Running out of disk space.. filegroup question

Hi all,
I need to keep a MSSQL 2000 database (replicating
subscription) running for 2 more weeks, but it is running
out of drive space on an E:/drive. There is space on the
F:/Drive. This is just theoretical, I've never done this,
but can I add another data file on this F:/ drive, in the
primary filegroup, and if so will the database continue to
grow on this new disk space. If not, will I have to
manually move some tables to the new file.
Please help. I'm running out of time. Thanks.
Don SalugaDon,
yes, you can add the new file to the existing filegroup.
You won't be able to move objects to this file unless you
create a new filegroup and add the new file to it, however
in your case this is probably not required as when new
space is required in the database, it is added in
proportional fill manner (relative to the %occupied space
of the 2 files).
HTH,
Paul Ibison|||Thanks so much Paul.
I'll try adding the second file to the primary filegroup.
Just one question about the proportional fill manner
(relative to the %occupied space. If drive E:/ has 471MBs
free and Drive F:\ (which will hold the new file) has 20
GBs free, will Drive E: still fill up and stop the
database or will the data just flow to the F:/ drive?
of the 2 files). Thanks.
Don
>--Original Message--
>Don,
>yes, you can add the new file to the existing filegroup.
>You won't be able to move objects to this file unless you
>create a new filegroup and add the new file to it,
however
>in your case this is probably not required as when new
>space is required in the database, it is added in
>proportional fill manner (relative to the %occupied space
>of the 2 files).
>HTH,
>Paul Ibison
>.
>|||Don,
from BOL: "if file f1 has 100 megabytes (MB) free and file
f2 has 200 MB free, one extent is allocated from file f1,
two extents from file f2, and so on. This way both files
become full at about the same time, and simple striping is
achieved".
So, in your case I'd avoid creating a huge file on your
new disk, but create a file of the size of your existing
datafile. That way there shouldn't be the old datafile
should never need to increase in size. If you want more
space, you just add another file to the primary filegroup
but on the new disk.
HTH,
Paul Ibison
>--Original Message--
>Thanks so much Paul.
>I'll try adding the second file to the primary
filegroup.
>Just one question about the proportional fill manner
>(relative to the %occupied space. If drive E:/ has 471MBs
>free and Drive F:\ (which will hold the new file) has 20
>GBs free, will Drive E: still fill up and stop the
>database or will the data just flow to the F:/ drive?
>of the 2 files). Thanks.
>Don
>>--Original Message--
>>Don,
>>yes, you can add the new file to the existing filegroup.
>>You won't be able to move objects to this file unless
you
>>create a new filegroup and add the new file to it,
>however
>>in your case this is probably not required as when new
>>space is required in the database, it is added in
>>proportional fill manner (relative to the %occupied
space
>>of the 2 files).
>>HTH,
>>Paul Ibison
>>.
>.
>|||IIRC, data will flow to the new empty file before the old file will expand
beyond its current size. Once they both have the same free space
(relative), I'm not sure how SQL Server will decide which one to grow. To
prolong the wait, just make sure the new file is bigger than the old one.
;-)
--
http://www.aspfaq.com/
(Reverse address to reply.)
<anonymous@.discussions.microsoft.com> wrote in message
news:1ac8701c44f03$2b1996d0$a101280a@.phx.gbl...
> Thanks so much Paul.
> I'll try adding the second file to the primary filegroup.
> Just one question about the proportional fill manner
> (relative to the %occupied space. If drive E:/ has 471MBs
> free and Drive F:\ (which will hold the new file) has 20
> GBs free, will Drive E: still fill up and stop the
> database or will the data just flow to the F:/ drive?
> of the 2 files). Thanks.
> Don
> >--Original Message--
> >Don,
> >yes, you can add the new file to the existing filegroup.
> >You won't be able to move objects to this file unless you
> >create a new filegroup and add the new file to it,
> however
> >in your case this is probably not required as when new
> >space is required in the database, it is added in
> >proportional fill manner (relative to the %occupied space
> >of the 2 files).
> >HTH,
> >Paul Ibison
> >.
> >|||Thanks Paul and Aaron,
I added the second primary group file to the F:/ Drive and
it looks like the data is going to there much faster than
to the E:/ drive that was filling up. It may be too early
to tell the exact ratio of E to F of data flow. It looks
like this fix saved the day.
Don
>--Original Message--
>IIRC, data will flow to the new empty file before the old
file will expand
>beyond its current size. Once they both have the same
free space
>(relative), I'm not sure how SQL Server will decide which
one to grow. To
>prolong the wait, just make sure the new file is bigger
than the old one.
>;-)
>--
>http://www.aspfaq.com/
>(Reverse address to reply.)
>
>
><anonymous@.discussions.microsoft.com> wrote in message
>news:1ac8701c44f03$2b1996d0$a101280a@.phx.gbl...
>> Thanks so much Paul.
>> I'll try adding the second file to the primary
filegroup.
>> Just one question about the proportional fill manner
>> (relative to the %occupied space. If drive E:/ has
471MBs
>> free and Drive F:\ (which will hold the new file) has 20
>> GBs free, will Drive E: still fill up and stop the
>> database or will the data just flow to the F:/ drive?
>> of the 2 files). Thanks.
>> Don
>> >--Original Message--
>> >Don,
>> >yes, you can add the new file to the existing
filegroup.
>> >You won't be able to move objects to this file unless
you
>> >create a new filegroup and add the new file to it,
>> however
>> >in your case this is probably not required as when new
>> >space is required in the database, it is added in
>> >proportional fill manner (relative to the %occupied
space
>> >of the 2 files).
>> >HTH,
>> >Paul Ibison
>> >.
>> >
>
>.
>|||To prevent any further SQL initiated filegrowth on your E: drive you can disable automatic filegrow on the primary datafile
for this particular database all together and just allow the newly created data file on your other partition to grow, and/or add other data files as need arises. This will prevent SQL from filling up the precious remaining disk space (maybe you are already using more than 90%) on your E: drive before the system halts running out of diskspace. I occasionally have to do this to balance disk load on terabyte size dbs.|||Hi there,
One of our drives is completely filled up with a database file and so I would like to move some of the db objects to a newly created data file on another drive. Can anyone give me a hint on how to do this?
Thanks
Andreas
"Sassan Karai" wrote:
> To prevent any further SQL initiated filegrowth on your E: drive you can disable automatic filegrow on the primary datafile
> for this particular database all together and just allow the newly created data file on your other partition to grow, and/or add other data files as need arises. This will prevent SQL from filling up the precious remaining disk space (maybe you are already using more than 90%) on your E: drive before the system halts running out of diskspace. I occasionally have to do this to balance disk load on terabyte size dbs.
>|||Hi
http://support.microsoft.com/directory/article.asp?ID=kb;en-us;Q224071--
Moving SQL Server Databases to a New Location
"Andreas" <Andreas@.discussions.microsoft.com> wrote in message
news:58B7A052-6AAB-4E31-AD6F-A13F29A895CF@.microsoft.com...
> Hi there,
> One of our drives is completely filled up with a database file and so I
would like to move some of the db objects to a newly created data file on
another drive. Can anyone give me a hint on how to do this?
> Thanks
> Andreas
>
> "Sassan Karai" wrote:
> > To prevent any further SQL initiated filegrowth on your E: drive you can
disable automatic filegrow on the primary datafile
> > for this particular database all together and just allow the newly
created data file on your other partition to grow, and/or add other data
files as need arises. This will prevent SQL from filling up the precious
remaining disk space (maybe you are already using more than 90%) on your E:
drive before the system halts running out of diskspace. I occasionally have
to do this to balance disk load on terabyte size dbs.
> >

Help Restore Database

The drive where my SQL backup were being backed up had filled up last
wednesday. The drive that the MDF was on crashed but I still have the LDF on
a different drive and wednesday's backup on it. Will it still be possible to
get the data back if I restore its last complete backup and then some how
restore the current LDF?
> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com
|||Did the transaction log contain all transactions since the last full
database backup? If not, is the database set to FULL or BULK LOAD RECOVERY
or SIMPLE RECOVERY? Have there been transaction log backups?
Do as Dejan says and attempt a BACKUP LOG ... WITH NO_TRUNCATE to get all
committed transactions out.
You will need the database to NOT be in SIMPLE RECOVERY. You will need the
full transaction log and all log backups from the time of the last GOOD FULL
DATABASE backup.
You might be able to use a tool like Lumigent's Log Explorer to rewrite
transactions from the transaction log and replay against a restored
database.
Sincerely,
Anthony Thomas

"Dejan Sarka" <dejan_please_reply_to_newsgroups.sarka@.avtenta.si > wrote in
message news:O6fE$$SAFHA.2676@.TK2MSFTNGP12.phx.gbl...
> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com

Help Restore Database

The drive where my SQL backup were being backed up had filled up last
wednesday. The drive that the MDF was on crashed but I still have the LDF on
a different drive and wednesday's backup on it. Will it still be possible to
get the data back if I restore its last complete backup and then some how
restore the current LDF?> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
--
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com|||Did the transaction log contain all transactions since the last full
database backup? If not, is the database set to FULL or BULK LOAD RECOVERY
or SIMPLE RECOVERY? Have there been transaction log backups?
Do as Dejan says and attempt a BACKUP LOG ... WITH NO_TRUNCATE to get all
committed transactions out.
You will need the database to NOT be in SIMPLE RECOVERY. You will need the
full transaction log and all log backups from the time of the last GOOD FULL
DATABASE backup.
You might be able to use a tool like Lumigent's Log Explorer to rewrite
transactions from the transaction log and replay against a restored
database.
Sincerely,
Anthony Thomas
"Dejan Sarka" <dejan_please_reply_to_newsgroups.sarka@.avtenta.si> wrote in
message news:O6fE$$SAFHA.2676@.TK2MSFTNGP12.phx.gbl...
> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
--
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com

Help Restore Database

The drive where my SQL backup were being backed up had filled up last
wednesday. The drive that the MDF was on crashed but I still have the LDF o
n
a different drive and wednesday's backup on it. Will it still be possible t
o
get the data back if I restore its last complete backup and then some how
restore the current LDF?> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com|||Did the transaction log contain all transactions since the last full
database backup? If not, is the database set to FULL or BULK LOAD RECOVERY
or SIMPLE RECOVERY? Have there been transaction log backups?
Do as Dejan says and attempt a BACKUP LOG ... WITH NO_TRUNCATE to get all
committed transactions out.
You will need the database to NOT be in SIMPLE RECOVERY. You will need the
full transaction log and all log backups from the time of the last GOOD FULL
DATABASE backup.
You might be able to use a tool like Lumigent's Log Explorer to rewrite
transactions from the transaction log and replay against a restored
database.
Sincerely,
Anthony Thomas
"Dejan Sarka" <dejan_please_reply_to_newsgroups.sarka@.avtenta.si> wrote in
message news:O6fE$$SAFHA.2676@.TK2MSFTNGP12.phx.gbl...
> The drive where my SQL backup were being backed up had filled up last
> wednesday. The drive that the MDF was on crashed but I still have the LDF
on
> a different drive and wednesday's backup on it. Will it still be possible
to
> get the data back if I restore its last complete backup and then some how
> restore the current LDF?
Try to backup the last log with NO_TRUNCATE option first, and then do the
restore, including the last log backup. This way you might be able to
restore everything up to crash. Check the option mentioned in Books OnLine.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com

Sunday, February 19, 2012

help required :- Table space management in sql server 2000

Hi ,

if we have two file group in a particular sql server 2000 database (c and d drive), and in that database suppose one particular table (location c drive) is growing very fast, i want to move it to D: drive file group. so how we can do it.

Thanks

Shiva

You can create or rebuild an existing clustered index on the table specifying the other filegroup. The data and the clustered index always reside on the same filegroup so creating or rebuilding the clustered index on the other filegroup will force the data over to the other filegroup.

-Sue