Saturday, February 25, 2012

Data and log files on separate disks

The production database of one of our clients is set up with both the data
and log files on the same disk. We suggested that they should separate them
out to eliminate disk contention and to eliminate I/O problems. The DBA at
the client site came back saying that he does not believe this is necessary.
Are we wrong in suggesting that the data and log files should be on separate
disks?
The client database is about 20 GB.
Thanks in advance.
"Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> The production database of one of our clients is set up with both the data
> and log files on the same disk. We suggested that they should separate
> them
> out to eliminate disk contention and to eliminate I/O problems. The DBA at
> the client site came back saying that he does not believe this is
> necessary.
> Are we wrong in suggesting that the data and log files should be on
> separate
> disks?
No, you're not.
However, whether it actually helps their performance is a good question.
If it's small enough and low volume enough, it won't help there.
If say the machine can only support 2 disks in a RAID 1 config, this
solution is "ok" given the machine.
If the machine can support more RAIDs (say 4 disks) then they're probably
better off separating them just because then if two disks fail, they're less
likely to actually suffer data loss.

> The client database is about 20 GB.
> Thanks in advance.
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
|||Thanks for the reply. As I mentioned the database is about 20GB and there is
plenty of activity during office hours and during other scheduled task runs.
Do you still believe separating the data and log files will improve some of
the bottlenecks.
Thanks
"Greg D. Moore (Strider)" wrote:

> "Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
> news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> No, you're not.
> However, whether it actually helps their performance is a good question.
> If it's small enough and low volume enough, it won't help there.
> If say the machine can only support 2 disks in a RAID 1 config, this
> solution is "ok" given the machine.
> If the machine can support more RAIDs (say 4 disks) then they're probably
> better off separating them just because then if two disks fail, they're less
> likely to actually suffer data loss.
>
>
> --
> Greg Moore
> SQL Server DBA Consulting Remote and Onsite available!
> Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
>
>
|||"Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:9ABCC48E-C789-482F-8F42-D02AB663E307@.microsoft.com...
> Thanks for the reply. As I mentioned the database is about 20GB and there
> is
> plenty of activity during office hours and during other scheduled task
> runs.
> Do you still believe separating the data and log files will improve some
> of
> the bottlenecks.
Is it experiencing disk I/O bottlenecks?
If so, it would probably help. But again. 20GB and 'plenty of activity'
doesn't really tell enough to say for sure.
[vbcol=seagreen]
> Thanks
>
> "Greg D. Moore (Strider)" wrote:
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
|||Frank1213 wrote:
> Thanks for the reply. As I mentioned the database is about 20GB and there is
> plenty of activity during office hours and during other scheduled task runs.
> Do you still believe separating the data and log files will improve some of
> the bottlenecks.
> Thanks
>
Hi,
Maybe you should ask is the disk is in their SAN. It's true that in most
cases it's good practice to have your database and logfiles on seperate
disk - both for performance reasons but also for disaster recovery
reasons. There are a few cases where this doesn't really make any
difference though. If they e.g. are using a HP EVA SAN there isn't any
performance reason to have the files on different disks because in the
end these disk will share the same physical spindles. The EVA SAN simply
puts all the disks in one big diskgroup and then on top of that you can
create your virtual disks. This means that if you create 2 virtual disks
and present to a server, the server will see it as 2 disks. In the end
it's not any different than just creating 1 virtual disk and put
everything on that single virtual disk - it's still the same physical
spindles it puts the data on.
If this is the case with your customer that could be the reason for why
the DBA answers like he do.
Regards
Steen Schlter Persson
Database Administrator / System Administrator
|||Thanks to both of you for your answers.
""Steen Schlüter Persson (DK)"" wrote:

> Frank1213 wrote:
> Hi,
> Maybe you should ask is the disk is in their SAN. It's true that in most
> cases it's good practice to have your database and logfiles on seperate
> disk - both for performance reasons but also for disaster recovery
> reasons. There are a few cases where this doesn't really make any
> difference though. If they e.g. are using a HP EVA SAN there isn't any
> performance reason to have the files on different disks because in the
> end these disk will share the same physical spindles. The EVA SAN simply
> puts all the disks in one big diskgroup and then on top of that you can
> create your virtual disks. This means that if you create 2 virtual disks
> and present to a server, the server will see it as 2 disks. In the end
> it's not any different than just creating 1 virtual disk and put
> everything on that single virtual disk - it's still the same physical
> spindles it puts the data on.
> If this is the case with your customer that could be the reason for why
> the DBA answers like he do.
> --
> Regards
> Steen Schlüter Persson
> Database Administrator / System Administrator
>

Data and log files on separate disks

The production database of one of our clients is set up with both the data
and log files on the same disk. We suggested that they should separate them
out to eliminate disk contention and to eliminate I/O problems. The DBA at
the client site came back saying that he does not believe this is necessary.
Are we wrong in suggesting that the data and log files should be on separate
disks?
The client database is about 20 GB.
Thanks in advance."Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> The production database of one of our clients is set up with both the data
> and log files on the same disk. We suggested that they should separate
> them
> out to eliminate disk contention and to eliminate I/O problems. The DBA at
> the client site came back saying that he does not believe this is
> necessary.
> Are we wrong in suggesting that the data and log files should be on
> separate
> disks?
No, you're not.
However, whether it actually helps their performance is a good question.
If it's small enough and low volume enough, it won't help there.
If say the machine can only support 2 disks in a RAID 1 config, this
solution is "ok" given the machine.
If the machine can support more RAIDs (say 4 disks) then they're probably
better off separating them just because then if two disks fail, they're less
likely to actually suffer data loss.
> The client database is about 20 GB.
> Thanks in advance.
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html|||Thanks for the reply. As I mentioned the database is about 20GB and there is
plenty of activity during office hours and during other scheduled task runs.
Do you still believe separating the data and log files will improve some of
the bottlenecks.
Thanks
"Greg D. Moore (Strider)" wrote:
> "Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
> news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> > The production database of one of our clients is set up with both the data
> > and log files on the same disk. We suggested that they should separate
> > them
> > out to eliminate disk contention and to eliminate I/O problems. The DBA at
> > the client site came back saying that he does not believe this is
> > necessary.
> > Are we wrong in suggesting that the data and log files should be on
> > separate
> > disks?
> No, you're not.
> However, whether it actually helps their performance is a good question.
> If it's small enough and low volume enough, it won't help there.
> If say the machine can only support 2 disks in a RAID 1 config, this
> solution is "ok" given the machine.
> If the machine can support more RAIDs (say 4 disks) then they're probably
> better off separating them just because then if two disks fail, they're less
> likely to actually suffer data loss.
>
> > The client database is about 20 GB.
> > Thanks in advance.
>
> --
> Greg Moore
> SQL Server DBA Consulting Remote and Onsite available!
> Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
>
>|||"Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:9ABCC48E-C789-482F-8F42-D02AB663E307@.microsoft.com...
> Thanks for the reply. As I mentioned the database is about 20GB and there
> is
> plenty of activity during office hours and during other scheduled task
> runs.
> Do you still believe separating the data and log files will improve some
> of
> the bottlenecks.
Is it experiencing disk I/O bottlenecks?
If so, it would probably help. But again. 20GB and 'plenty of activity'
doesn't really tell enough to say for sure.
> Thanks
>
> "Greg D. Moore (Strider)" wrote:
>> "Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
>> news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
>> > The production database of one of our clients is set up with both the
>> > data
>> > and log files on the same disk. We suggested that they should separate
>> > them
>> > out to eliminate disk contention and to eliminate I/O problems. The DBA
>> > at
>> > the client site came back saying that he does not believe this is
>> > necessary.
>> > Are we wrong in suggesting that the data and log files should be on
>> > separate
>> > disks?
>> No, you're not.
>> However, whether it actually helps their performance is a good question.
>> If it's small enough and low volume enough, it won't help there.
>> If say the machine can only support 2 disks in a RAID 1 config, this
>> solution is "ok" given the machine.
>> If the machine can support more RAIDs (say 4 disks) then they're probably
>> better off separating them just because then if two disks fail, they're
>> less
>> likely to actually suffer data loss.
>>
>> > The client database is about 20 GB.
>> > Thanks in advance.
>>
>> --
>> Greg Moore
>> SQL Server DBA Consulting Remote and Onsite available!
>> Email: sql (at) greenms.com
>> http://www.greenms.com/sqlserver.html
>>
--
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html|||Frank1213 wrote:
> Thanks for the reply. As I mentioned the database is about 20GB and there is
> plenty of activity during office hours and during other scheduled task runs.
> Do you still believe separating the data and log files will improve some of
> the bottlenecks.
> Thanks
>
Hi,
Maybe you should ask is the disk is in their SAN. It's true that in most
cases it's good practice to have your database and logfiles on seperate
disk - both for performance reasons but also for disaster recovery
reasons. There are a few cases where this doesn't really make any
difference though. If they e.g. are using a HP EVA SAN there isn't any
performance reason to have the files on different disks because in the
end these disk will share the same physical spindles. The EVA SAN simply
puts all the disks in one big diskgroup and then on top of that you can
create your virtual disks. This means that if you create 2 virtual disks
and present to a server, the server will see it as 2 disks. In the end
it's not any different than just creating 1 virtual disk and put
everything on that single virtual disk - it's still the same physical
spindles it puts the data on.
If this is the case with your customer that could be the reason for why
the DBA answers like he do.
--
Regards
Steen Schlüter Persson
Database Administrator / System Administrator|||Thanks to both of you for your answers.
""Steen Schlüter Persson (DK)"" wrote:
> Frank1213 wrote:
> > Thanks for the reply. As I mentioned the database is about 20GB and there is
> > plenty of activity during office hours and during other scheduled task runs.
> > Do you still believe separating the data and log files will improve some of
> > the bottlenecks.
> > Thanks
> >
> >
> Hi,
> Maybe you should ask is the disk is in their SAN. It's true that in most
> cases it's good practice to have your database and logfiles on seperate
> disk - both for performance reasons but also for disaster recovery
> reasons. There are a few cases where this doesn't really make any
> difference though. If they e.g. are using a HP EVA SAN there isn't any
> performance reason to have the files on different disks because in the
> end these disk will share the same physical spindles. The EVA SAN simply
> puts all the disks in one big diskgroup and then on top of that you can
> create your virtual disks. This means that if you create 2 virtual disks
> and present to a server, the server will see it as 2 disks. In the end
> it's not any different than just creating 1 virtual disk and put
> everything on that single virtual disk - it's still the same physical
> spindles it puts the data on.
> If this is the case with your customer that could be the reason for why
> the DBA answers like he do.
> --
> Regards
> Steen Schlüter Persson
> Database Administrator / System Administrator
>

Data and log files on separate disks

The production database of one of our clients is set up with both the data
and log files on the same disk. We suggested that they should separate them
out to eliminate disk contention and to eliminate I/O problems. The DBA at
the client site came back saying that he does not believe this is necessary.
Are we wrong in suggesting that the data and log files should be on separate
disks?
The client database is about 20 GB.
Thanks in advance."Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> The production database of one of our clients is set up with both the data
> and log files on the same disk. We suggested that they should separate
> them
> out to eliminate disk contention and to eliminate I/O problems. The DBA at
> the client site came back saying that he does not believe this is
> necessary.
> Are we wrong in suggesting that the data and log files should be on
> separate
> disks?
No, you're not.
However, whether it actually helps their performance is a good question.
If it's small enough and low volume enough, it won't help there.
If say the machine can only support 2 disks in a RAID 1 config, this
solution is "ok" given the machine.
If the machine can support more RAIDs (say 4 disks) then they're probably
better off separating them just because then if two disks fail, they're less
likely to actually suffer data loss.

> The client database is about 20 GB.
> Thanks in advance.
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html|||Thanks for the reply. As I mentioned the database is about 20GB and there is
plenty of activity during office hours and during other scheduled task runs.
Do you still believe separating the data and log files will improve some of
the bottlenecks.
Thanks
"Greg D. Moore (Strider)" wrote:

> "Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
> news:80F4426D-0326-40D5-9EF4-B42853066EE6@.microsoft.com...
> No, you're not.
> However, whether it actually helps their performance is a good question.
> If it's small enough and low volume enough, it won't help there.
> If say the machine can only support 2 disks in a RAID 1 config, this
> solution is "ok" given the machine.
> If the machine can support more RAIDs (say 4 disks) then they're probably
> better off separating them just because then if two disks fail, they're le
ss
> likely to actually suffer data loss.
>
>
> --
> Greg Moore
> SQL Server DBA Consulting Remote and Onsite available!
> Email: sql (at) greenms.com [url]http://www.greenms.com/sqlserver.html[/ur
l]
>
>|||"Frank1213" <Frank1213@.discussions.microsoft.com> wrote in message
news:9ABCC48E-C789-482F-8F42-D02AB663E307@.microsoft.com...
> Thanks for the reply. As I mentioned the database is about 20GB and there
> is
> plenty of activity during office hours and during other scheduled task
> runs.
> Do you still believe separating the data and log files will improve some
> of
> the bottlenecks.
Is it experiencing disk I/O bottlenecks?
If so, it would probably help. But again. 20GB and 'plenty of activity'
doesn't really tell enough to say for sure.
[vbcol=seagreen]
> Thanks
>
> "Greg D. Moore (Strider)" wrote:
>
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html|||Frank1213 wrote:
> Thanks for the reply. As I mentioned the database is about 20GB and there
is
> plenty of activity during office hours and during other scheduled task run
s.
> Do you still believe separating the data and log files will improve some o
f
> the bottlenecks.
> Thanks
>
Hi,
Maybe you should ask is the disk is in their SAN. It's true that in most
cases it's good practice to have your database and logfiles on seperate
disk - both for performance reasons but also for disaster recovery
reasons. There are a few cases where this doesn't really make any
difference though. If they e.g. are using a HP EVA SAN there isn't any
performance reason to have the files on different disks because in the
end these disk will share the same physical spindles. The EVA SAN simply
puts all the disks in one big diskgroup and then on top of that you can
create your virtual disks. This means that if you create 2 virtual disks
and present to a server, the server will see it as 2 disks. In the end
it's not any different than just creating 1 virtual disk and put
everything on that single virtual disk - it's still the same physical
spindles it puts the data on.
If this is the case with your customer that could be the reason for why
the DBA answers like he do.
Regards
Steen Schlter Persson
Database Administrator / System Administrator|||Thanks to both of you for your answers.
""Steen Schlüter Persson (DK)"" wrote:

> Frank1213 wrote:
> Hi,
> Maybe you should ask is the disk is in their SAN. It's true that in most
> cases it's good practice to have your database and logfiles on seperate
> disk - both for performance reasons but also for disaster recovery
> reasons. There are a few cases where this doesn't really make any
> difference though. If they e.g. are using a HP EVA SAN there isn't any
> performance reason to have the files on different disks because in the
> end these disk will share the same physical spindles. The EVA SAN simply
> puts all the disks in one big diskgroup and then on top of that you can
> create your virtual disks. This means that if you create 2 virtual disks
> and present to a server, the server will see it as 2 disks. In the end
> it's not any different than just creating 1 virtual disk and put
> everything on that single virtual disk - it's still the same physical
> spindles it puts the data on.
> If this is the case with your customer that could be the reason for why
> the DBA answers like he do.
> --
> Regards
> Steen Schlüter Persson
> Database Administrator / System Administrator
>

Data and log files and Raid

I have a development SQL 2000 server system running on Windows 2000 Pro.
I keep this system updated with all production data so I can test
everything.
This question might not be answerable without knowing what kind of data
I have, but I'll ask anyway.
I was thinking about adding a couple of SATA disks to the system. Here
are some possibilities:
1) Leave the log file on its current IDE disk, and set the new SATA
disks up as Raid 0, and put the data file there,
2) Move the log to one of the new SATA disks and the data to the other
SATA disk,
3) Set up the new SATA disks as Raid 0 and put the log and the data both
on the new RAID logical drive that results;
4) Some other arrangement?
It's a 45 GB database that's mostly used for reading (Select queries)
except when I update the database with new transactions and customer
account records daily.
One question...When writing data to a database, is the log file as
active as the data file? Isn't everything written to the log file and
then to the data file?
Thanks for any insight with this very general question.
David WalkerDWalker wrote:
> I have a development SQL 2000 server system running on Windows 2000 Pro.
> I keep this system updated with all production data so I can test
> everything.
> This question might not be answerable without knowing what kind of data
> I have, but I'll ask anyway.
> I was thinking about adding a couple of SATA disks to the system. Here
> are some possibilities:
> 1) Leave the log file on its current IDE disk, and set the new SATA
> disks up as Raid 0, and put the data file there,
> 2) Move the log to one of the new SATA disks and the data to the other
> SATA disk,
> 3) Set up the new SATA disks as Raid 0 and put the log and the data both
> on the new RAID logical drive that results;
> 4) Some other arrangement?
> It's a 45 GB database that's mostly used for reading (Select queries)
> except when I update the database with new transactions and customer
> account records daily.
> One question...When writing data to a database, is the log file as
> active as the data file? Isn't everything written to the log file and
> then to the data file?
> Thanks for any insight with this very general question.
> David Walker
>
Hi David,
All changes are written to the Log first and then to the Data files when
a Checkpoint occours. You could use (3) and leave the System tables on
the IDE disks. This would ensure speed and minimal security (if you
lose the RAID then the system tables are safe on the IDE, if you lose
the IDE then you have most likely lost the OS as well;)
James|||James Wilson <JamesWilson@.bryggemail.dk> wrote in
news:umGxjbwLGHA.3496@.TK2MSFTNGP14.phx.gbl:

> Hi David,
> All changes are written to the Log first and then to the Data files
> when a Checkpoint occours. You could use (3) and leave the System
> tables on the IDE disks. This would ensure speed and minimal security
> (if you lose the RAID then the system tables are safe on the IDE, if
> you lose the IDE then you have most likely lost the OS as well;)
> James
>
OK, thanks for the advice.
David

Data and log files and Raid

I have a development SQL 2000 server system running on Windows 2000 Pro.
I keep this system updated with all production data so I can test
everything.
This question might not be answerable without knowing what kind of data
I have, but I'll ask anyway.
I was thinking about adding a couple of SATA disks to the system. Here
are some possibilities:
1) Leave the log file on its current IDE disk, and set the new SATA
disks up as Raid 0, and put the data file there,
2) Move the log to one of the new SATA disks and the data to the other
SATA disk,
3) Set up the new SATA disks as Raid 0 and put the log and the data both
on the new RAID logical drive that results;
4) Some other arrangement?
It's a 45 GB database that's mostly used for reading (Select queries)
except when I update the database with new transactions and customer
account records daily.
One question...When writing data to a database, is the log file as
active as the data file? Isn't everything written to the log file and
then to the data file?
Thanks for any insight with this very general question.
David Walker
DWalker wrote:
> I have a development SQL 2000 server system running on Windows 2000 Pro.
> I keep this system updated with all production data so I can test
> everything.
> This question might not be answerable without knowing what kind of data
> I have, but I'll ask anyway.
> I was thinking about adding a couple of SATA disks to the system. Here
> are some possibilities:
> 1) Leave the log file on its current IDE disk, and set the new SATA
> disks up as Raid 0, and put the data file there,
> 2) Move the log to one of the new SATA disks and the data to the other
> SATA disk,
> 3) Set up the new SATA disks as Raid 0 and put the log and the data both
> on the new RAID logical drive that results;
> 4) Some other arrangement?
> It's a 45 GB database that's mostly used for reading (Select queries)
> except when I update the database with new transactions and customer
> account records daily.
> One question...When writing data to a database, is the log file as
> active as the data file? Isn't everything written to the log file and
> then to the data file?
> Thanks for any insight with this very general question.
> David Walker
>
Hi David,
All changes are written to the Log first and then to the Data files when
a Checkpoint occours. You could use (3) and leave the System tables on
the IDE disks. This would ensure speed and minimal security (if you
lose the RAID then the system tables are safe on the IDE, if you lose
the IDE then you have most likely lost the OS as well;)
James
|||James Wilson <JamesWilson@.bryggemail.dk> wrote in
news:umGxjbwLGHA.3496@.TK2MSFTNGP14.phx.gbl:

> Hi David,
> All changes are written to the Log first and then to the Data files
> when a Checkpoint occours. You could use (3) and leave the System
> tables on the IDE disks. This would ensure speed and minimal security
> (if you lose the RAID then the system tables are safe on the IDE, if
> you lose the IDE then you have most likely lost the OS as well;)
> James
>
OK, thanks for the advice.
David

Data and log files and Raid

I have a development SQL 2000 server system running on Windows 2000 Pro.
I keep this system updated with all production data so I can test
everything.
This question might not be answerable without knowing what kind of data
I have, but I'll ask anyway.
I was thinking about adding a couple of SATA disks to the system. Here
are some possibilities:
1) Leave the log file on its current IDE disk, and set the new SATA
disks up as Raid 0, and put the data file there,
2) Move the log to one of the new SATA disks and the data to the other
SATA disk,
3) Set up the new SATA disks as Raid 0 and put the log and the data both
on the new RAID logical drive that results;
4) Some other arrangement?
It's a 45 GB database that's mostly used for reading (Select queries)
except when I update the database with new transactions and customer
account records daily.
One question...When writing data to a database, is the log file as
active as the data file? Isn't everything written to the log file and
then to the data file?
Thanks for any insight with this very general question.
David WalkerDWalker wrote:
> I have a development SQL 2000 server system running on Windows 2000 Pro.
> I keep this system updated with all production data so I can test
> everything.
> This question might not be answerable without knowing what kind of data
> I have, but I'll ask anyway.
> I was thinking about adding a couple of SATA disks to the system. Here
> are some possibilities:
> 1) Leave the log file on its current IDE disk, and set the new SATA
> disks up as Raid 0, and put the data file there,
> 2) Move the log to one of the new SATA disks and the data to the other
> SATA disk,
> 3) Set up the new SATA disks as Raid 0 and put the log and the data both
> on the new RAID logical drive that results;
> 4) Some other arrangement?
> It's a 45 GB database that's mostly used for reading (Select queries)
> except when I update the database with new transactions and customer
> account records daily.
> One question...When writing data to a database, is the log file as
> active as the data file? Isn't everything written to the log file and
> then to the data file?
> Thanks for any insight with this very general question.
> David Walker
>
Hi David,
All changes are written to the Log first and then to the Data files when
a Checkpoint occours. You could use (3) and leave the System tables on
the IDE disks. This would ensure speed and minimal security (if you
lose the RAID then the system tables are safe on the IDE, if you lose
the IDE then you have most likely lost the OS as well;)
James|||James Wilson <JamesWilson@.bryggemail.dk> wrote in
news:umGxjbwLGHA.3496@.TK2MSFTNGP14.phx.gbl:
> Hi David,
> All changes are written to the Log first and then to the Data files
> when a Checkpoint occours. You could use (3) and leave the System
> tables on the IDE disks. This would ensure speed and minimal security
> (if you lose the RAID then the system tables are safe on the IDE, if
> you lose the IDE then you have most likely lost the OS as well;)
> James
>
OK, thanks for the advice.
David

Data and Log files

Installing SQL 2005, how can I specify what volume to put my Data and
Log files on? I do not see the option.
thanks
RickRick
For system databases?
"Rick" <drummer10980@.gmail.com> wrote in message
news:1193907987.542408.315030@.v3g2000hsg.googlegroups.com...
> Installing SQL 2005, how can I specify what volume to put my Data and
> Log files on? I do not see the option.
> thanks
> Rick
>|||On Nov 1, 5:44 am, "Uri Dimant" <u...@.iscar.co.il> wrote:
> Rick
> For system databases?
> "Rick" <drummer10...@.gmail.com> wrote in message
> news:1193907987.542408.315030@.v3g2000hsg.googlegroups.com...
>
> > Installing SQL 2005, how can I specify what volume to put my Data and
> > Log files on? I do not see the option.
> > thanks
> > Rick- Hide quoted text -
> - Show quoted text -
for Databases I add, in 2000 I could use options to change drive
letters.
Rick|||Rick
RESTORE DATABASE has WITH MOVE option to place files on different location.
See also sp_attach stored procedure
"Rick" <drummer10980@.gmail.com> wrote in message
news:1193919657.400277.87190@.y42g2000hsy.googlegroups.com...
> On Nov 1, 5:44 am, "Uri Dimant" <u...@.iscar.co.il> wrote:
>> Rick
>> For system databases?
>> "Rick" <drummer10...@.gmail.com> wrote in message
>> news:1193907987.542408.315030@.v3g2000hsg.googlegroups.com...
>>
>> > Installing SQL 2005, how can I specify what volume to put my Data and
>> > Log files on? I do not see the option.
>> > thanks
>> > Rick- Hide quoted text -
>> - Show quoted text -
> for Databases I add, in 2000 I could use options to change drive
> letters.
> Rick
>|||You mean default directory for database files? You can do that in SSMS. Object Explorer, right-click
your instance, properties and the "Database settings" page.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Rick" <drummer10980@.gmail.com> wrote in message
news:1193919657.400277.87190@.y42g2000hsy.googlegroups.com...
> On Nov 1, 5:44 am, "Uri Dimant" <u...@.iscar.co.il> wrote:
>> Rick
>> For system databases?
>> "Rick" <drummer10...@.gmail.com> wrote in message
>> news:1193907987.542408.315030@.v3g2000hsg.googlegroups.com...
>>
>> > Installing SQL 2005, how can I specify what volume to put my Data and
>> > Log files on? I do not see the option.
>> > thanks
>> > Rick- Hide quoted text -
>> - Show quoted text -
> for Databases I add, in 2000 I could use options to change drive
> letters.
> Rick
>|||On Nov 1, 8:39 am, "Tibor Karaszi"
<tibor_please.no.email_kara...@.hotmail.nomail.com> wrote:
> You mean default directory for database files? You can do that in SSMS. Object Explorer, right-click
> your instance, properties and the "Database settings" page.
> --
> Tibor Karaszi, SQL Server MVPhttp://www.karaszi.com/sqlserver/default.asphttp://sqlblog.com/blogs/tibor_karaszi
> "Rick" <drummer10...@.gmail.com> wrote in message
> news:1193919657.400277.87190@.y42g2000hsy.googlegroups.com...
>
> > On Nov 1, 5:44 am, "Uri Dimant" <u...@.iscar.co.il> wrote:
> >> Rick
> >> For system databases?
> >> "Rick" <drummer10...@.gmail.com> wrote in message
> >>news:1193907987.542408.315030@.v3g2000hsg.googlegroups.com...
> >> > Installing SQL 2005, how can I specify what volume to put my Data and
> >> > Log files on? I do not see the option.
> >> > thanks
> >> > Rick- Hide quoted text -
> >> - Show quoted text -
> > for Databases I add, in 2000 I could use options to change drive
> > letters.
> > Rick- Hide quoted text -
> - Show quoted text -
that is what i needed, thanks
Rick

Data and log file naming conventions

I have several user databases across several servers.
Some of the physical data files are stored as databasename.mdf,
databasename_data.mdf...
Some of the physical log files are stored as databasename.ldf,
databasename_log.ldf...
Does any one has any naming convention suggestion on this?
Currently SQL2K. Planning to move SQL2005 when it is available.
Thanks,
HarryUse whatever convention is logical and meets your needs; the main thing
is to be consistent.
Personally, I tend to stick with the GUI default <dbname>_data.mdf &
<dbname>_log.ldf for everything I can (using default values for things,
if they're sensible & reasonable, tends to avoid the pain of having to
memorise different conventions). For secondary data files I tend to use
<dbname>n_data.ndf where n is just a simple incrementing integer (1, 2,
3...), eg. mydb_Data.mdf, mydb_Log.ldf, mydb1_Data.ndf, mydb2_Data.ndf, etc.
CREATE DATABASE <dbname>, with no extra parameters, will create the
database with <dbname>.mdf & <dbname>_log.ldf but I've always thought
that to be inconsistent (with "_log" but not "_data") so I've always
gone with the recommendation of the GUI (with the _data & _log postfixes).
*mike hodgson*
blog: http://sqlnerd.blogspot.com
HarrySmith wrote:

>I have several user databases across several servers.
>Some of the physical data files are stored as databasename.mdf,
>databasename_data.mdf...
>Some of the physical log files are stored as databasename.ldf,
>databasename_log.ldf...
>Does any one has any naming convention suggestion on this?
>Currently SQL2K. Planning to move SQL2005 when it is available.
>Thanks,
>Harry
>
>

Data and log file naming conventions

I have several user databases across several servers.
Some of the physical data files are stored as databasename.mdf,
databasename_data.mdf...
Some of the physical log files are stored as databasename.ldf,
databasename_log.ldf...
Does any one has any naming convention suggestion on this?
Currently SQL2K. Planning to move SQL2005 when it is available.
Thanks,
Harry
Use whatever convention is logical and meets your needs; the main thing
is to be consistent.
Personally, I tend to stick with the GUI default <dbname>_data.mdf &
<dbname>_log.ldf for everything I can (using default values for things,
if they're sensible & reasonable, tends to avoid the pain of having to
memorise different conventions). For secondary data files I tend to use
<dbname>n_data.ndf where n is just a simple incrementing integer (1, 2,
3...), eg. mydb_Data.mdf, mydb_Log.ldf, mydb1_Data.ndf, mydb2_Data.ndf, etc.
CREATE DATABASE <dbname>, with no extra parameters, will create the
database with <dbname>.mdf & <dbname>_log.ldf but I've always thought
that to be inconsistent (with "_log" but not "_data") so I've always
gone with the recommendation of the GUI (with the _data & _log postfixes).
*mike hodgson*
blog: http://sqlnerd.blogspot.com
HarrySmith wrote:

>I have several user databases across several servers.
>Some of the physical data files are stored as databasename.mdf,
>databasename_data.mdf...
>Some of the physical log files are stored as databasename.ldf,
>databasename_log.ldf...
>Does any one has any naming convention suggestion on this?
>Currently SQL2K. Planning to move SQL2005 when it is available.
>Thanks,
>Harry
>
>

Data and log file naming conventions

I have several user databases across several servers.
Some of the physical data files are stored as databasename.mdf,
databasename_data.mdf...
Some of the physical log files are stored as databasename.ldf,
databasename_log.ldf...
Does any one has any naming convention suggestion on this?
Currently SQL2K. Planning to move SQL2005 when it is available.
Thanks,
HarryThis is a multi-part message in MIME format.
--020803060805070804090702
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Use whatever convention is logical and meets your needs; the main thing
is to be consistent.
Personally, I tend to stick with the GUI default <dbname>_data.mdf &
<dbname>_log.ldf for everything I can (using default values for things,
if they're sensible & reasonable, tends to avoid the pain of having to
memorise different conventions). For secondary data files I tend to use
<dbname>n_data.ndf where n is just a simple incrementing integer (1, 2,
3...), eg. mydb_Data.mdf, mydb_Log.ldf, mydb1_Data.ndf, mydb2_Data.ndf, etc.
CREATE DATABASE <dbname>, with no extra parameters, will create the
database with <dbname>.mdf & <dbname>_log.ldf but I've always thought
that to be inconsistent (with "_log" but not "_data") so I've always
gone with the recommendation of the GUI (with the _data & _log postfixes).
--
*mike hodgson*
blog: http://sqlnerd.blogspot.com
HarrySmith wrote:
>I have several user databases across several servers.
>Some of the physical data files are stored as databasename.mdf,
>databasename_data.mdf...
>Some of the physical log files are stored as databasename.ldf,
>databasename_log.ldf...
>Does any one has any naming convention suggestion on this?
>Currently SQL2K. Planning to move SQL2005 when it is available.
>Thanks,
>Harry
>
>
--020803060805070804090702
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>Use whatever convention is logical and meets your needs; the main
thing is to be consistent.<br>
<br>
Personally, I tend to stick with the GUI default
<dbname>_data.mdf & <dbname>_log.ldf for everything I
can (using default values for things, if they're sensible &
reasonable, tends to avoid the pain of having to memorise different
conventions). For secondary data files I tend to use
<dbname>n_data.ndf where n is just a simple incrementing integer
(1, 2, 3...), eg. mydb_Data.mdf, mydb_Log.ldf, mydb1_Data.ndf,
mydb2_Data.ndf, etc.<br>
<br>
CREATE DATABASE <dbname>, with no extra parameters, will create
the database with <dbname>.mdf & <dbname>_log.ldf but
I've always thought that to be inconsistent (with "_log" but not
"_data") so I've always gone with the recommendation of the GUI (with
the _data & _log postfixes).<br>
</tt>
<div class="moz-signature">
<title></title>
<meta http-equiv="Content-Type" content="text/html; ">
<p><span lang="en-au"><font face="Tahoma" size="2">--<br>
</font></span> <b><span lang="en-au"><font face="Tahoma" size="2">mike
hodgson</font></span></b><span lang="en-au"><br>
<font face="Tahoma" size="2">blog:</font><font face="Tahoma" size="2"> <a
href="http://links.10026.com/?link=http://sqlnerd.blogspot.com</a></font></span>">http://sqlnerd.blogspot.com">http://sqlnerd.blogspot.com</a></font></span>
</p>
</div>
<br>
<br>
HarrySmith wrote:
<blockquote cite="midONj5bFAtFHA.3604@.tk2msftngp13.phx.gbl" type="cite">
<pre wrap="">I have several user databases across several servers.
Some of the physical data files are stored as databasename.mdf,
databasename_data.mdf...
Some of the physical log files are stored as databasename.ldf,
databasename_log.ldf...
Does any one has any naming convention suggestion on this?
Currently SQL2K. Planning to move SQL2005 when it is available.
Thanks,
Harry
</pre>
</blockquote>
</body>
</html>
--020803060805070804090702--

Data and index pages

As found in a book saying about Index pages:
'Unlike data pages, there is no limit to the total number of entries that
can be made on an index page.'
What is that mean ?
It's wrong. An index page has the exact same limit as a data page. There's
8k in a page minus the header size and the slot array and that's all the
space that available on the page for records (entries). There's a finite
limit defined using the minimum possible record size plus the slot array
overhead for each record - I'd work it out for you exactly but I can't
remember the minimum possible record size off the top of my head. The max is
somewhere around 310-320 records per page though.
Regards
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Alan" <NOSPAMalan_pltse@.yahoo.com.au> wrote in message
news:uXr6ainqEHA.1644@.tk2msftngp13.phx.gbl...
> As found in a book saying about Index pages:
> 'Unlike data pages, there is no limit to the total number of entries that
> can be made on an index page.'
> What is that mean ?
>

Data and index pages

As found in a book saying about Index pages:
'Unlike data pages, there is no limit to the total number of entries that
can be made on an index page.'
What is that mean ?It's wrong. An index page has the exact same limit as a data page. There's
8k in a page minus the header size and the slot array and that's all the
space that available on the page for records (entries). There's a finite
limit defined using the minimum possible record size plus the slot array
overhead for each record - I'd work it out for you exactly but I can't
remember the minimum possible record size off the top of my head. The max is
somewhere around 310-320 records per page though.
Regards
--
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Alan" <NOSPAMalan_pltse@.yahoo.com.au> wrote in message
news:uXr6ainqEHA.1644@.tk2msftngp13.phx.gbl...
> As found in a book saying about Index pages:
> 'Unlike data pages, there is no limit to the total number of entries that
> can be made on an index page.'
> What is that mean ?
>

Data Analyzer Reviews

Does anyone use this in their organization?
1. What is the administrative effort? Does it require a lot of
setup/support?
2. What is the learning curve like for the users?
3. What products are comparable to this?
it is really easy to use; it isn't as powerful as Excel.
it doesn't really take more than about 5 minutes to show people how ot use
it-- but i htink that it is pretty much worthless (unless oyu need to create
powerpoint slides based on OLAP data)
-aaron
"michelle" <michelle@.nospam.com> wrote in message
news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
> Does anyone use this in their organization?
> 1. What is the administrative effort? Does it require a lot of
> setup/support?
> 2. What is the learning curve like for the users?
> 3. What products are comparable to this?
>
|||I like Data Analyzer - I'm about to deply a data mart with Data Analyzer as
the primary front-end tool.
-Paul Nielsen, SQL Server MVP
SQL Server 2000 Bible, Wiley Press
Enterprise Data Architect, www.Compassion.com
"michelle" <michelle@.nospam.com> wrote in message
news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
> Does anyone use this in their organization?
> 1. What is the administrative effort? Does it require a lot of
> setup/support?
> 2. What is the learning curve like for the users?
> 3. What products are comparable to this?
>
|||I'd be curious to hear back from you after this has been deployed.
Thanks!
"Paul Nielsen" <pnielsen@.us.ci.org> wrote in message
news:%23K8LFjw0EHA.1204@.TK2MSFTNGP10.phx.gbl...
> I like Data Analyzer - I'm about to deply a data mart with Data Analyzer
as
> the primary front-end tool.
>
> --
> -Paul Nielsen, SQL Server MVP
> SQL Server 2000 Bible, Wiley Press
> Enterprise Data Architect, www.Compassion.com
>
>
> "michelle" <michelle@.nospam.com> wrote in message
> news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
>

Data Analyzer Reviews

Does anyone use this in their organization?
1. What is the administrative effort? Does it require a lot of
setup/support?
2. What is the learning curve like for the users?
3. What products are comparable to this?it is really easy to use; it isn't as powerful as Excel.
it doesn't really take more than about 5 minutes to show people how ot use
it-- but i htink that it is pretty much worthless (unless oyu need to create
powerpoint slides based on OLAP data)
-aaron
"michelle" <michelle@.nospam.com> wrote in message
news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
> Does anyone use this in their organization?
> 1. What is the administrative effort? Does it require a lot of
> setup/support?
> 2. What is the learning curve like for the users?
> 3. What products are comparable to this?
>|||I like Data Analyzer - I'm about to deply a data mart with Data Analyzer as
the primary front-end tool.
-Paul Nielsen, SQL Server MVP
SQL Server 2000 Bible, Wiley Press
Enterprise Data Architect, www.Compassion.com
"michelle" <michelle@.nospam.com> wrote in message
news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
> Does anyone use this in their organization?
> 1. What is the administrative effort? Does it require a lot of
> setup/support?
> 2. What is the learning curve like for the users?
> 3. What products are comparable to this?
>|||I'd be curious to hear back from you after this has been deployed.
Thanks!
"Paul Nielsen" <pnielsen@.us.ci.org> wrote in message
news:%23K8LFjw0EHA.1204@.TK2MSFTNGP10.phx.gbl...
> I like Data Analyzer - I'm about to deply a data mart with Data Analyzer
as
> the primary front-end tool.
>
> --
> -Paul Nielsen, SQL Server MVP
> SQL Server 2000 Bible, Wiley Press
> Enterprise Data Architect, www.Compassion.com
>
>
> "michelle" <michelle@.nospam.com> wrote in message
> news:ua$pXECzEHA.3996@.TK2MSFTNGP10.phx.gbl...
>

Data alignment in Textbox

Hi All,
I am working on a report, in this report a textbox is present, which is expected to show string. This string length is larger than what textbox can accommodate in single line. I want this textbox to show only right part of the string in case it can accommodate full string.
After using the right alignment I assumed it would do show, however it does not work like that. It always shows the left part of string in case, string is bigger than width of textbox.
Restriction from design:
1. Cannot increase the width of textbox.
2. Cannot use the Can Grow = true to show string in multiple lines.

Below is the example of my issue:
Say there is a string: "Microsoft SQL Server Reporting Services".
because the textbox width is not sufficient to see full string, I want to "Reporting Service". Which is of same size which column can accommodate. So I used Right alignment in textbox. however text box shows "Microsoft SQL Server". So, is there a solution to see required text in the textbox.

Hi,

Data alignment in Textbox

Hi All,
I am working on a report, in this report a textbox is present, which is expected to show string. This string length is larger than what textbox can accommodate in single line. I want this textbox to show only right part of the string in case it can accommodate full string.
After using the right alignment I assumed it would do show, however it does not work like that. It always shows the left part of string in case, string is bigger than width of textbox.
Restriction from design:
1. Cannot increase the width of textbox.
2. Cannot use the Can Grow = true to show string in multiple lines.

Below is the example of my issue:
Say there is a string: "Microsoft SQL Server Reporting Services".
because the textbox width is not sufficient to see full string, I want to "Reporting Service". Which is of same size which column can accommodate. So I used Right alignment in textbox. however text box shows "Microsoft SQL Server". So, is there a solution to see required text in the textbox.

Hi,

Data aggregation, syhcronization, and search

Hello All,
I know that this problem is not SQL Server specific but I decided to
post it here because it is a problem that I am certain many of you
expericenced (or at least thought about).
In my system, I have a central SQL Server Database and number of
remote "data providers". Some of these data providers are other SQL
Servers and others are other databases or other data provider services
that expose a database-like interface.
We provide two levels of search capability in the system. The user can
search either the central database, or search one specific data
provider. One of the new requirements, was to provide a global search,
which would search the central database and all the data providers at
once.
Performing a distributed is prohibitive in our scenario because we
have many data providers and they remotelly located. To minimize the
search time, my first reaction was to create a copy of the data from
the remote providers on the central database and keep it in synch with
the data in the remote data providers. By doing this, I would expect
to simplify the search by having simply a search in the central
database.
However, a number of new question concerning data synchronization
arise:
1. How can I keep the data in the central db in synch with the remote
data providers? (If they all were SQL Server databases, I would use
merger replication...but they aren't?)
2. How to handle disconnects? If the remote provider disconnets and
reconnects, some of the data might be stale. In pronciple, I could
take a new snapshot and keep the data in synch from that point.
However, this is very expensive!! Do you know of any other techniques
for data synchronization that would minimize network traffic?
3. Is this a good approach? What do you think?
Your opinion is gratly appreciated.
Kind regards
CD
Hi
"crbd98@.yahoo.com" wrote:

> Hello All,
> I know that this problem is not SQL Server specific but I decided to
> post it here because it is a problem that I am certain many of you
> expericenced (or at least thought about).
> In my system, I have a central SQL Server Database and number of
> remote "data providers". Some of these data providers are other SQL
> Servers and others are other databases or other data provider services
> that expose a database-like interface.
> We provide two levels of search capability in the system. The user can
> search either the central database, or search one specific data
> provider. One of the new requirements, was to provide a global search,
> which would search the central database and all the data providers at
> once.
> Performing a distributed is prohibitive in our scenario because we
> have many data providers and they remotelly located. To minimize the
> search time, my first reaction was to create a copy of the data from
> the remote providers on the central database and keep it in synch with
> the data in the remote data providers. By doing this, I would expect
> to simplify the search by having simply a search in the central
> database.
> However, a number of new question concerning data synchronization
> arise:
> 1. How can I keep the data in the central db in synch with the remote
> data providers? (If they all were SQL Server databases, I would use
> merger replication...but they aren't?)
> 2. How to handle disconnects? If the remote provider disconnets and
> reconnects, some of the data might be stale. In pronciple, I could
> take a new snapshot and keep the data in synch from that point.
> However, this is very expensive!! Do you know of any other techniques
> for data synchronization that would minimize network traffic?
> 3. Is this a good approach? What do you think?
> Your opinion is gratly appreciated.
> Kind regards
> CD
>
You don't say how you currently search the remote data providers! It may be
more acceptable for the users if the global search initially searched the
central database and returned the results and then searched the remote
databases which would return something to the user quicker and reduce the
need to speed up the remote searches.
If you held the data centrally, you would also need to know how much latency
would be acceptable for the data, if you could get away with uploading once a
day out of hours then this could be an easier solution to implement.
John
|||Answers inline.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
<crbd98@.yahoo.com> wrote in message
news:1176094164.164628.321030@.q75g2000hsh.googlegr oups.com...
> Hello All,
> I know that this problem is not SQL Server specific but I decided to
> post it here because it is a problem that I am certain many of you
> expericenced (or at least thought about).
> In my system, I have a central SQL Server Database and number of
> remote "data providers". Some of these data providers are other SQL
> Servers and others are other databases or other data provider services
> that expose a database-like interface.
> We provide two levels of search capability in the system. The user can
> search either the central database, or search one specific data
> provider. One of the new requirements, was to provide a global search,
> which would search the central database and all the data providers at
> once.
> Performing a distributed is prohibitive in our scenario because we
> have many data providers and they remotelly located. To minimize the
> search time, my first reaction was to create a copy of the data from
> the remote providers on the central database and keep it in synch with
> the data in the remote data providers. By doing this, I would expect
> to simplify the search by having simply a search in the central
> database.
> However, a number of new question concerning data synchronization
> arise:
> 1. How can I keep the data in the central db in synch with the remote
> data providers? (If they all were SQL Server databases, I would use
> merger replication...but they aren't?)
I would use transactional replication to replicate the remote SQL Servers to
the central location. For the non-SQL Server data providers depending on the
amount of changes, the volume of data and whether you can track changes you
should be able to write something that will bring the data locally.
> 2. How to handle disconnects? If the remote provider disconnets and
> reconnects, some of the data might be stale. In pronciple, I could
> take a new snapshot and keep the data in synch from that point.
> However, this is very expensive!! Do you know of any other techniques
> for data synchronization that would minimize network traffic?
You need to implement some method of change tracking so only the changes
will move each time rather than the entire data set.
> 3. Is this a good approach? What do you think?
>
The network hop is always problematic and moving data locally is one
approach to avoid it. Another option might be to move all providers locally
and then have the clients use a remote access solution to access the central
server/repository. This will work well if your links are stable and well
connected.

> Your opinion is gratly appreciated.
> Kind regards
> CD
>

Data added before publication created does not replicate - why?

Hello,

I have a small three server development environment where I am getting my feet wet with replication. I have set up peer-to-peer transactional replication and it works fine for data added to the publication's table after the publication was created. However, rows in the table that existed prior to the publication's creation have never replicated. If any of the "old" rows are edited they cause an error on the subscribing servers when the replicator attempts to apply updates to rows that do not exist.

How can I get the old rows that predate the publication to replicate?

Thanks,

BCB

I believe to setup peer-to-peer replication, you'll need to initialize the data at each node through backup and restore. You can find more info here.

http://msdn2.microsoft.com/en-us/library/ms146914.aspx

Gary

data acess class

hi
i was reading book about asp.net and i found example for a dataacess class but i didn't understand this part

Private m_FieldData As New NameObjectCollection
Private _m_ConnectionString As String
Private m_dbConnection As SqlConnection
Private Sub AddParameters( _
ByVal objCommand As SqlCommand, _
ByVal objValues() As Object)

Dim objValue As Object
Dim I As Integer
Dim objParameter As SqlParameter

objCommand.Parameters.Clear()
SqlCommandBuilder.DeriveParameters(objCommand)

I = 0
For Each objParameter In objCommand.Parameters
If objParameter.Direction = ParameterDirection.Input _
Or objParameter.Direction = _
ParameterDirection.InputOutput Then

objValue = objValues(I)
objParameter.Value = objValue
I = I + 1
End If
Next
End Sub

Private Sub AddFieldParameters _
(ByVal objCommand As SqlCommand)

Dim objParameter As SqlParameter

objCommand.Parameters.Clear()
SqlCommandBuilder.DeriveParameters(objCommand)

For Each objParameter In objCommand.Parameters
objParameter.Value = _
_FieldData.Item(objParameter.ParameterName. _
Substring(1))
Next
End Sub
Public Function ExecDataReader _
(ByVal strStoredProc As String, _
ByVal ParamArray objValues() As Object) _
As SqlDataReader

Dim objCommand As SqlCommand
Dim objReader As SqlDataReader

objCommand = New SqlCommand

objCommand.CommandText = strStoredProc
objCommand.CommandType = CommandType.StoredProcedure
objCommand.Connection = dbConnection

Try
objCommand.Connection.Open()
If (objValues.Length = 0) Then
AddFieldParameters(objCommand)
Else
AddParameters(objCommand, objValues)
End If
objReader = objCommand. _
ExecuteReader(CommandBehavior.CloseConnection)
Catch ex As Exception
If objCommand.Connection.State.Open Then
objCommand.Connection.Close()
End If
End Try

Return objReader
End Function
can anybody help me what the author want to doTamer, can you be more specific?

Thanks|||hi i don't understand sub AddParameters and addfieldparameter
and why to add values as an array
and the parameter have only one single value why to pass an array of object i can pass a single value hope u understand me|||I'm going to have to kind of guess here as I don't know the source or the context of the script. That being said

Looking at just the AddFieldParameters sub:
---------------------------------
Private Sub AddFieldParameters (ByVal objCommand As SqlCommand)

Dim objParameter As SqlParameter

objCommand.Parameters.Clear()
SqlCommandBuilder.DeriveParameters(objCommand)

For Each objParameter In objCommand.Parameters
objParameter.Value = FieldData.Item(objParameter.ParameterName.Substring(1))
Next
End Sub
---------------------------------

I read this as the SQL command is being passed into the sub as a value and that value can have multiple lines to it. The FieldData object is being created with each line of the SQL command as a different entry in the array.

The AddParameters looks pretty much the same.

Does this answer your question?

I can look into this further if you provide me with the origional source and location of the script.

Thanks

Data Acess aplication block __How to use it on server without Microsoft

Hi all
As per my earlier conversation with Ciaran (thx for reply) I have
installed the MS APplication block on the server , when i ran Build
Enterprise Library file and Install Services from (batch files )
programme files menu it was asking for visual studio 2003 , I have only
.net framework on the server how can i use the MS application block
data access library on my server plz help...
Mukesh Agarwal
mukesh.nitb@.gmail.com
Delhi India
Ciaran O''Donnell wrote:
> The error you are getting is because the enterprise library wants to
write events to the event log and setting this up requires registry
permissions. You need to installutil the dlls for the enterprise library
(this is covered in the docs somewhere). The reason it is writing to the
event log is because the connection failed. If you setup the event log
access correctly then you will have an eventlog entry telling you why
the connection failed.
>
> HTH
>
> Ciaran O'Donnell
>
> "Mukesh" wrote:
>
>> Hi
>>
>> I have Microsoft Enterprise Library 2005 installed on my local system.
>> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
Server 2000.
>>
>> I am developing a web application in which i am using data Access
Application Block for data access.
>>
>> I have a remote web n data server with asp.net 1.1 support
>>
>> the application is working fine here on the local server(web & data).
>>
>> when i change the data server path to the remote server it also
working fine but
>> When I uploaded the application on the remote server n tested there
it gives me the following err
>>
>>
>> ex.message was
>>
>>
>> >>The type initializer for
>>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
>>threw an exception.
>>
>> ex.Source was
>>
>> ..........Microsoft.Practices.EnterpriseLibrary.Data
>>
>> ex.trace was
>>
>> at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
command) at property.m4.Button2_Click(Object sender, EventArgs e)
>>
>>
>> Plz help me why this is happening.........
>>
>> Mukesh Kumar agarwal
>> Delhi
>> India
>>
>>
>>
>>
>>
>>The build file calls devenv.exe, which is Visual Studio 2003. You best
option now is a command line compilation of the library. Follow the docs on
the csc.exe (C#) or vbc.exe (VB.NET) compilers.
--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
*************************************************
Think outside of the box!
*************************************************
"Mukesh" <efextra@.newsgroups.nospam> wrote in message
news:45056076.3060606@.newsgroups.nospam...
> Hi all
> As per my earlier conversation with Ciaran (thx for reply) I have
> installed the MS APplication block on the server , when i ran Build
> Enterprise Library file and Install Services from (batch files ) programme
> files menu it was asking for visual studio 2003 , I have only .net
> framework on the server how can i use the MS application block data access
> library on my server plz help...
> Mukesh Agarwal
> mukesh.nitb@.gmail.com
> Delhi India
>
> Ciaran O''Donnell wrote:
> > The error you are getting is because the enterprise library wants to
> write events to the event log and setting this up requires registry
> permissions. You need to installutil the dlls for the enterprise library
> (this is covered in the docs somewhere). The reason it is writing to the
> event log is because the connection failed. If you setup the event log
> access correctly then you will have an eventlog entry telling you why the
> connection failed.
> >
> > HTH
> >
> > Ciaran O'Donnell
> >
> > "Mukesh" wrote:
> >
> >> Hi
> >>
> >> I have Microsoft Enterprise Library 2005 installed on my local
> >> system.
> >> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> >>
> >> I am developing a web application in which i am using data Access
> Application Block for data access.
> >>
> >> I have a remote web n data server with asp.net 1.1 support
> >>
> >> the application is working fine here on the local server(web & data).
> >>
> >> when i change the data server path to the remote server it also
> working fine but
> >> When I uploaded the application on the remote server n tested there
> it gives me the following err
> >>
> >>
> >> ex.message was
> >>
> >>
> >> >>The type initializer for
> >>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
> >>threw an exception.
> >>
> >> ex.Source was
> >>
> >> ..........Microsoft.Practices.EnterpriseLibrary.Data
> >>
> >> ex.trace was
> >>
> >> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
> >>
> >>
> >> Plz help me why this is happening.........
> >>
> >> Mukesh Kumar agarwal
> >> Delhi
> >> India
> >>
> >>
> >>
> >>
> >>
> >>|||I didnt mean install the enterprise library with the MSI file.
I mean't for each dll in the EL you use:
call InstallUtil.exe passing in the name of the dll. This will invoke the
custominstaller classes inside the dll's to register them selves in teh event
log and things.
Ciaran O'Donnell
"Mukesh" wrote:
> Hi all
> As per my earlier conversation with Ciaran (thx for reply) I have
> installed the MS APplication block on the server , when i ran Build
> Enterprise Library file and Install Services from (batch files )
> programme files menu it was asking for visual studio 2003 , I have only
> .net framework on the server how can i use the MS application block
> data access library on my server plz help...
> Mukesh Agarwal
> mukesh.nitb@.gmail.com
> Delhi India
>
> Ciaran O''Donnell wrote:
> > The error you are getting is because the enterprise library wants to
> write events to the event log and setting this up requires registry
> permissions. You need to installutil the dlls for the enterprise library
> (this is covered in the docs somewhere). The reason it is writing to the
> event log is because the connection failed. If you setup the event log
> access correctly then you will have an eventlog entry telling you why
> the connection failed.
> >
> > HTH
> >
> > Ciaran O'Donnell
> >
> > "Mukesh" wrote:
> >
> >> Hi
> >>
> >> I have Microsoft Enterprise Library 2005 installed on my local system.
> >> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> >>
> >> I am developing a web application in which i am using data Access
> Application Block for data access.
> >>
> >> I have a remote web n data server with asp.net 1.1 support
> >>
> >> the application is working fine here on the local server(web & data).
> >>
> >> when i change the data server path to the remote server it also
> working fine but
> >> When I uploaded the application on the remote server n tested there
> it gives me the following err
> >>
> >>
> >> ex.message was
> >>
> >>
> >> >>The type initializer for
> >>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
> >>threw an exception.
> >>
> >> ex.Source was
> >>
> >> ..........Microsoft.Practices.EnterpriseLibrary.Data
> >>
> >> ex.trace was
> >>
> >> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
> >>
> >>
> >> Plz help me why this is happening.........
> >>
> >> Mukesh Kumar agarwal
> >> Delhi
> >> India
> >>
> >>
> >>
> >>
> >>
> >>
>|||Install the .msi on a development machine with VS2003.
Look at the .bat files.
You need to not find the compile code (csc or dev.exe), but rather the code
that installs the services.
You need the rights to install services , especially on a Server Machine.
Make sure the framework (free download) is installed on the server also.
"Mukesh" <efextra@.newsgroups.nospam> wrote in message
news:45056076.3060606@.newsgroups.nospam...
> Hi all
> As per my earlier conversation with Ciaran (thx for reply) I have
> installed the MS APplication block on the server , when i ran Build
> Enterprise Library file and Install Services from (batch files )
> programme files menu it was asking for visual studio 2003 , I have only
> .net framework on the server how can i use the MS application block
> data access library on my server plz help...
> Mukesh Agarwal
> mukesh.nitb@.gmail.com
> Delhi India
>
> Ciaran O''Donnell wrote:
> > The error you are getting is because the enterprise library wants to
> write events to the event log and setting this up requires registry
> permissions. You need to installutil the dlls for the enterprise library
> (this is covered in the docs somewhere). The reason it is writing to the
> event log is because the connection failed. If you setup the event log
> access correctly then you will have an eventlog entry telling you why
> the connection failed.
> >
> > HTH
> >
> > Ciaran O'Donnell
> >
> > "Mukesh" wrote:
> >
> >> Hi
> >>
> >> I have Microsoft Enterprise Library 2005 installed on my local
system.
> >> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> >>
> >> I am developing a web application in which i am using data Access
> Application Block for data access.
> >>
> >> I have a remote web n data server with asp.net 1.1 support
> >>
> >> the application is working fine here on the local server(web & data).
> >>
> >> when i change the data server path to the remote server it also
> working fine but
> >> When I uploaded the application on the remote server n tested there
> it gives me the following err
> >>
> >>
> >> ex.message was
> >>
> >>
> >> >>The type initializer for
>>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnect
ionFailedEvent"
> >>threw an exception.
> >>
> >> ex.Source was
> >>
> >> ..........Microsoft.Practices.EnterpriseLibrary.Data
> >>
> >> ex.trace was
> >>
> >> at
>
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFai
ledEvent.Fire(String
> connectionString) at
>
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentati
onFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
>
Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandW
rapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
> >>
> >>
> >> Plz help me why this is happening.........
> >>
> >> Mukesh Kumar agarwal
> >> Delhi
> >> India
> >>
> >>
> >>
> >>
> >>
> >>|||Dear Mukesh,
I am interested in this issue. Would you mind letting me know the result of
the suggestions? If you need further assistance, feel free to let me
know. I will be more than happy to be of assistance.
Have a great day!
Charles Wang
Microsoft Online Community Support
======================================================When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
======================================================This posting is provided "AS IS" with no warranties, and confers no rights.
======================================================

Data Acess aplication block

Hi
I have Microsoft Enterprise Library 2005 installed on my local system.
I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
Server 2000.
I am developing a web application in which i am using data Access
Application Block for data access.
I have a remote web n data server with asp.net 1.1 support
the application is working fine here on the local server(web & data).
when i change the data server path to the remote server it also working
fine but
When I uploaded the application on the remote server n tested there it
gives me the following err
ex.message was
[vbcol=seagreen]
ex.Source was
.........Microsoft.Practices.EnterpriseLibrary.Data
ex.trace was
at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFai
ledEvent.Fire(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentati
onFacade.ConnectionFailed(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandW
rapper
command) at property.m4.Button2_Click(Object sender, EventArgs e)
Plz help me why this is happening.........
Mukesh Kumar agarwal
Delhi
IndiaMukesh,
Are you sure that the user that ASP.NET is running under has access to
the database you are trying to reach? It seems as if this is an error on
connecting.
Hope this helps.
- Nicholas Paldino [.NET/C# MVP]
- mvp@.spam.guard.caspershouse.com
"Mukesh" <efextra@.newsgroups.nospam> wrote in message
news:u6JBICB1GHA.4264@.TK2MSFTNGP05.phx.gbl...
> Hi
> I have Microsoft Enterprise Library 2005 installed on my local system.
> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> I am developing a web application in which i am using data Access
> Application Block for data access.
> I have a remote web n data server with asp.net 1.1 support
> the application is working fine here on the local server(web & data).
> when i change the data server path to the remote server it also working
> fine but
> When I uploaded the application on the remote server n tested there it
> gives me the following err
>
> ex.message was
>
> ex.Source was
> .........Microsoft.Practices.EnterpriseLibrary.Data
> ex.trace was
> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionF
ailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumenta
tionFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBComman
dWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
>
> Plz help me why this is happening.........
> Mukesh Kumar agarwal
> Delhi
> India
>
>
>|||The error you are getting is because the enterprise library wants to write
events to the event log and setting this up requires registry permissions.
You need to installutil the dlls for the enterprise library (this is covered
in the docs somewhere). The reason it is writing to the event log is because
the connection failed. If you setup the event log access correctly then you
will have an eventlog entry telling you why the connection failed.
HTH
Ciaran O'Donnell
"Mukesh" wrote:

> Hi
> I have Microsoft Enterprise Library 2005 installed on my local system.
> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> I am developing a web application in which i am using data Access
> Application Block for data access.
> I have a remote web n data server with asp.net 1.1 support
> the application is working fine here on the local server(web & data).
> when i change the data server path to the remote server it also working
> fine but
> When I uploaded the application on the remote server n tested there it
> gives me the following err
>
> ex.message was
>
> ex.Source was
> ..........Microsoft.Practices.EnterpriseLibrary.Data
> ex.trace was
> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionF
ailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumenta
tionFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBComman
dWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
>
> Plz help me why this is happening.........
> Mukesh Kumar agarwal
> Delhi
> India
>
>
>

Data Acess aplication block

Hi
I have Microsoft Enterprise Library 2005 installed on my local system.
I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
Server 2000.
I am developing a web application in which i am using data Access
Application Block for data access.
I have a remote web n data server with asp.net 1.1 support
the application is working fine here on the local server(web & data).
when i change the data server path to the remote server it also working
fine but
When I uploaded the application on the remote server n tested there it
gives me the following err
ex.message was
>>The type initializer for
>>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
>>threw an exception.
ex.Source was
.........Microsoft.Practices.EnterpriseLibrary.Data
ex.trace was
at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
connectionString) at
Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
command) at property.m4.Button2_Click(Object sender, EventArgs e)
Plz help me why this is happening.........
Mukesh Kumar agarwal
Delhi
IndiaMukesh,
Are you sure that the user that ASP.NET is running under has access to
the database you are trying to reach? It seems as if this is an error on
connecting.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mvp@.spam.guard.caspershouse.com
"Mukesh" <efextra@.newsgroups.nospam> wrote in message
news:u6JBICB1GHA.4264@.TK2MSFTNGP05.phx.gbl...
> Hi
> I have Microsoft Enterprise Library 2005 installed on my local system.
> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> I am developing a web application in which i am using data Access
> Application Block for data access.
> I have a remote web n data server with asp.net 1.1 support
> the application is working fine here on the local server(web & data).
> when i change the data server path to the remote server it also working
> fine but
> When I uploaded the application on the remote server n tested there it
> gives me the following err
>
> ex.message was
>
> >>The type initializer for
> >>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
> >>threw an exception.
> ex.Source was
> .........Microsoft.Practices.EnterpriseLibrary.Data
> ex.trace was
> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
>
> Plz help me why this is happening.........
> Mukesh Kumar agarwal
> Delhi
> India
>
>
>|||The error you are getting is because the enterprise library wants to write
events to the event log and setting this up requires registry permissions.
You need to installutil the dlls for the enterprise library (this is covered
in the docs somewhere). The reason it is writing to the event log is because
the connection failed. If you setup the event log access correctly then you
will have an eventlog entry telling you why the connection failed.
HTH
Ciaran O'Donnell
"Mukesh" wrote:
> Hi
> I have Microsoft Enterprise Library 2005 installed on my local system.
> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
> Server 2000.
> I am developing a web application in which i am using data Access
> Application Block for data access.
> I have a remote web n data server with asp.net 1.1 support
> the application is working fine here on the local server(web & data).
> when i change the data server path to the remote server it also working
> fine but
> When I uploaded the application on the remote server n tested there it
> gives me the following err
>
> ex.message was
>
> >>The type initializer for
> >>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
> >>threw an exception.
> ex.Source was
> ..........Microsoft.Practices.EnterpriseLibrary.Data
> ex.trace was
> at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
> connectionString) at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
> command) at property.m4.Button2_Click(Object sender, EventArgs e)
>
> Plz help me why this is happening.........
> Mukesh Kumar agarwal
> Delhi
> India
>
>
>|||Hi all
As per my earlier conversation with Ciaran (thx for reply) I have
installed the MS APplication block on the server , when i ran Build
Enterprise Library file and Install Services from (batch files )
programme files menu it was asking for visual studio 2003 , I have only
.net framework on the server how can i use the MS application block
data access library on my server plz help...
Mukesh Agarwal
mukesh.nitb@.gmail.com
Delhi India
Ciaran O''Donnell wrote:
> The error you are getting is because the enterprise library wants to write
> events to the event log and setting this up requires registry permissions.
> You need to installutil the dlls for the enterprise library (this is covered
> in the docs somewhere). The reason it is writing to the event log is because
> the connection failed. If you setup the event log access correctly then you
> will have an eventlog entry telling you why the connection failed.
> HTH
> Ciaran O'Donnell
> "Mukesh" wrote:
>> Hi
>> I have Microsoft Enterprise Library 2005 installed on my local system.
>> I m also using ASp.net 1.1 And C3 as coding language , I have MS Sql
>> Server 2000.
>> I am developing a web application in which i am using data Access
>> Application Block for data access.
>> I have a remote web n data server with asp.net 1.1 support
>> the application is working fine here on the local server(web & data).
>> when i change the data server path to the remote server it also working
>> fine but
>> When I uploaded the application on the remote server n tested there it
>> gives me the following err
>>
>> ex.message was
>>
>> >>The type initializer for
>> >>"Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent"
>> >>threw an exception.
>> ex.Source was
>> ..........Microsoft.Practices.EnterpriseLibrary.Data
>> ex.trace was
>> at
>> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataConnectionFailedEvent.Fire(String
>> connectionString) at
>> Microsoft.Practices.EnterpriseLibrary.Data.Instrumentation.DataInstrumentationFacade.ConnectionFailed(String
>> connectionString) at
>> Microsoft.Practices.EnterpriseLibrary.Data.Database.OpenConnection() at
>> Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteReader(DBCommandWrapper
>> command) at property.m4.Button2_Click(Object sender, EventArgs e)
>>
>> Plz help me why this is happening.........
>> Mukesh Kumar agarwal
>> Delhi
>> India
>>
>>
>>|||Hello Mukesh,
As for the installation of instrumentation servcie of enterprise library
2005, I've posted some information from the enterprise lib's product
team(in your another duplicated thread in the
microsoft.public.dotnet.languages.csharp newsgroup) which include:
** how disable instrumentation of enterprise library (through custom build)
when deploy them to product environment.
** how to install the instrumentation services without vs 2003
installed(use the installUtil.exe in .net framework utilities):
For your convenience, I've pasted my reply in that thread below:
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
=============================================Hi Mukesh,
As for the Enterprise Library(2005) for .net framework 1.1, the
instrumentation services does need to be installed separately. And the
"install services" bat file does require the VS 2003 IDE installed on the
machine. Actually this is because instrumetation feature is mainly used in
development environment. For production environment, generally we do not
use them and can disable the setting at compilation time(through some build
flags).
Therefore, for your scenario, you can consider the following options:
1. Build a product version of the enterprise library which disable the
instrumentation in the build options(some conditional compile variables).
2. Instead of using the "Install Services" bat file, use the
InstallUtil.exe utility(shipped with .net framework 1.1 rather than vs
2003) to register the instrumentation service against each enterprise
library assembly (you will use in your application).
Here is a blog article from the product manager of enterprise library
(pattern&practice team) which has provide a complete description on the
instrumentation services of Enterprise library 2005(.net 1.1) and how to
disable it in custom build or install the service without VS 2003 IDE:
#Instrumentation in Enterprise Library
http://blogs.msdn.com/tomholl/archive/2005/02/18/376187.aspx
Hope this helps.
Sincerely,
Steven Cheng
===============================================================

Data access, DataReaders, DataSets, web pages and controls

I have a question about loading data on the page lode event. The question is more conceptual then how to.

Using C#, I would like to make a call to a SQL 2000 Server, with the use of a stored procedure return one row with eleven fields. Then use the data to fill five different controls. There is no manipulation of the data it is just presented as information. With a DataReader and the GetValues method using the resultant array I can fill the controls (or can I), or with a DataSet and the Load method do the same thing. Now this code can be placed in the code behind page or it can be implemented in a class. This is the only page that uses this combination of fields and controls; however I would think a more generic call to the data could be made then pick and chose the fields as needed. What process makes the most sense? Is what I just described even possible (as yet I haven't tried it)?

As always thanks in advance for any thoughts, comments, and suggestions.

hi Darel

i think u can create a function in a class and call that function in code behind. that function will return a dataset. u cannot use datareader as u have to fill more than one control in a function call.

Data access using Ent. Library Jan. 2006 release

Hello ...

Using Ent. Library Jan. 2006 release and .Net Framework 2.0, I'm connecting to SQL Server 2000 using Microsoft.Practices.EnterpriseLibrary.Data.Sql.

I have a windows service that processes jobs asynchronously and from time to time, I'm getting the following error --

"A connection was successfully established with the server, but then an error occurred during the pre-login handshake. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (TCP Provider error: 0 - An existing connection was forcibly closed by the remote host. "

What's surprising is the error message saying SQL Server 2005. Has anyone encountered and resolved this?

Thanks.

allanroy

I guess you installed the SNAC on your system, right ? Thats where the message comes from.

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de|||

What is SNAC?

Thanks.

allan

|||Nothing to eat ;-) It s the SQL Native Client.

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de|||

The SQL Native Client is installed in my client machine and not on the server that host the SQL Server 2000 and my windows services. Ones a job is requested from a client machine, the process is asynchronous and processing happens only on the server.

allan

|||Are you using connection pooling, if yes it could be that the connection used is not released from the pool, leading to the error message, that the server cannot be contacted.

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de