Showing posts with label sqlserver. Show all posts
Showing posts with label sqlserver. Show all posts

Monday, March 19, 2012

Creating SQLServer Jobs in Enterprise Manager

I would like to create a job in Enterprise manager that runs sp_who2
and write the output to a file. The filename would need to be appended
with a timestamp that makes the file unique. I can then write another
job that will cleanup the directory by deleting files that are older
than a specified date. This is a very simple process in unix platform.
I am hoping that it can be done in Windows but I don't know how?

Any help will be applicicated..You can send the output of a job step directly to a file (see the
Advanced tab), but there's no easy way to set the file name
dynamically. You might be able to use sp_update_jobstep to set it at
runtime, but then you would still have to do the cleanup part, which
would mean using xp_cmdshell.

Personally, I would use a script in a langauge like VBScript, Perl or
Python to do this:

1. Work out the correct filename
2. Call osql.exe to get the output into the file (see the -Q and -o
options)
3. Clean up any old files

You can then call the script from a job step - it's much easier to
manipulate files outside the database.

Simon

Sunday, March 11, 2012

Creating reports?

I am moving my Access DB to SQLServer, is it possible to use access for reports with SQL Srver ? if so what topic should i start searching or any link would be apreciated.
Thanksyou can attach (Files >> Get Extenal Data >> Link Tables) your new SQL DB to any access mdb by creating a DSN for that. once attached those foreign tables can be used as source of data for access reports.

Thursday, March 8, 2012

Creating RDL files at runtime

I created a CustomerReport.rdl from VS.NET. I previewed the report in
the SQLServer Report Manager and it shows the report. that is perfect.
Now what i did is, I opened the CustomerReport.rdl in Notedpad.
Obviously it shows me the XML format of the report design. I copied
all XML content of the report (Ctrl+A/paste) and copied into a new
notepad window and saved the new file as test.rdl.
Now when I open the test.rdl report from Report Manager, I see that
Iam asked to enter the SQLServer authentication (sa/password). Only
after I do the SQLServer authentication, Iam able to view the report
in the Report Manager. Why does it ask me so.
The thing is Iam playing with the rdl because I need to create reports
on the fly (at runtime) in my project requirement. Please share your
experiences if you've done something simialar.
thanks,
Anand SagarHello,
What kind of datasource are you using ? shared or private to the report ?
In Report Designer or Report Manager, connections to data sources are
managed by ReportDesigner or ReportingServices and credentials are stored
securily in Repository for ReportingServices. Credentials are not part of
RDL and you should not find then in Notepad. If you have a shared Datasource
you can configure it with ReportManager and reference it in your RDL, so you
will not have to authenticate again with Test.rdl
HTH
Jerome Berthaud (MCSD)
http://www.winsight.fr
"Anand Sagar" <anandsagar@.gmail.com> wrote in message
news:3f76a771.0408070018.29eb85ae@.posting.google.com...
> I created a CustomerReport.rdl from VS.NET. I previewed the report in
> the SQLServer Report Manager and it shows the report. that is perfect.
> Now what i did is, I opened the CustomerReport.rdl in Notedpad.
> Obviously it shows me the XML format of the report design. I copied
> all XML content of the report (Ctrl+A/paste) and copied into a new
> notepad window and saved the new file as test.rdl.
>
> Now when I open the test.rdl report from Report Manager, I see that
> Iam asked to enter the SQLServer authentication (sa/password). Only
> after I do the SQLServer authentication, Iam able to view the report
> in the Report Manager. Why does it ask me so.
>
> The thing is Iam playing with the rdl because I need to create reports
> on the fly (at runtime) in my project requirement. Please share your
> experiences if you've done something simialar.
> thanks,
> Anand Sagar|||Hi,
You can test it live on internet and change the parameter
ProductFamily=Food in ProductFamily=Food. Here you will find 4 ways to
start a MS Reporting Services Report as enduser:
http://128.171.208.112/ReportServer?%2fFoodmart+Sales&ProductFamily=Food
http://128.171.208.112/ReportServer?%2fFoodmart+Sales&rs%3aFormat=HTML4.0&ProductFamily=Food&rc%3aToolbar=True&rc%3aJavaScript=True&rc%3aLinkTarget=_top&rc%3aArea=Toolbar
http://128.171.208.112/ReportServer?%2fFoodmart+Sales&ProductFamily=Food&rs%3aFormat=HTML4.0&rc%3aToolbar=True&rc%3aJavaScript=True&rc%3aLinkTarget=_top&rc%3aArea=Report
Any other parameter can be used in an action from MS As 2000. For more
info: www.reportportal.com / www.gmsbv.nl
Regards,
Marco
www.gmsbv.nl - your partner for MS Analyses & Reporting Services in
Europe !
"Jerome BERTHAUD" <jerome.berthaud@.winsight.fr> wrote in message news:<uoKmx5IfEHA.3428@.TK2MSFTNGP11.phx.gbl>...
> Hello,
> What kind of datasource are you using ? shared or private to the report ?
> In Report Designer or Report Manager, connections to data sources are
> managed by ReportDesigner or ReportingServices and credentials are stored
> securily in Repository for ReportingServices. Credentials are not part of
> RDL and you should not find then in Notepad. If you have a shared Datasource
> you can configure it with ReportManager and reference it in your RDL, so you
> will not have to authenticate again with Test.rdl
> HTH
> Jerome Berthaud (MCSD)
> http://www.winsight.fr
>
> "Anand Sagar" <anandsagar@.gmail.com> wrote in message
> news:3f76a771.0408070018.29eb85ae@.posting.google.com...
> > I created a CustomerReport.rdl from VS.NET. I previewed the report in
> > the SQLServer Report Manager and it shows the report. that is perfect.
> >
> > Now what i did is, I opened the CustomerReport.rdl in Notedpad.
> > Obviously it shows me the XML format of the report design. I copied
> > all XML content of the report (Ctrl+A/paste) and copied into a new
> > notepad window and saved the new file as test.rdl.
> >
> >
> > Now when I open the test.rdl report from Report Manager, I see that
> > Iam asked to enter the SQLServer authentication (sa/password). Only
> > after I do the SQLServer authentication, Iam able to view the report
> > in the Report Manager. Why does it ask me so.
> >
> >
> > The thing is Iam playing with the rdl because I need to create reports
> > on the fly (at runtime) in my project requirement. Please share your
> > experiences if you've done something simialar.
> >
> > thanks,
> > Anand Sagar|||One additional comment to Jerome's posting: If you use the managed SQL
provider ("SQL") in the data source, you can use IntegratedSecurity for
testing purposes (and therefore no need for credentials):
<ConnectionProperties>
<DataProvider>SQL</DataProvider>
<IntegratedSecurity>true</IntegratedSecurity>
<ConnectString>data source=(local); ... </ConnectString>
</ConnectionProperties>
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Jerome BERTHAUD" <jerome.berthaud@.winsight.fr> wrote in message
news:uoKmx5IfEHA.3428@.TK2MSFTNGP11.phx.gbl...
> Hello,
> What kind of datasource are you using ? shared or private to the report ?
> In Report Designer or Report Manager, connections to data sources are
> managed by ReportDesigner or ReportingServices and credentials are stored
> securily in Repository for ReportingServices. Credentials are not part of
> RDL and you should not find then in Notepad. If you have a shared
Datasource
> you can configure it with ReportManager and reference it in your RDL, so
you
> will not have to authenticate again with Test.rdl
> HTH
> Jerome Berthaud (MCSD)
> http://www.winsight.fr
>
> "Anand Sagar" <anandsagar@.gmail.com> wrote in message
> news:3f76a771.0408070018.29eb85ae@.posting.google.com...
> > I created a CustomerReport.rdl from VS.NET. I previewed the report in
> > the SQLServer Report Manager and it shows the report. that is perfect.
> >
> > Now what i did is, I opened the CustomerReport.rdl in Notedpad.
> > Obviously it shows me the XML format of the report design. I copied
> > all XML content of the report (Ctrl+A/paste) and copied into a new
> > notepad window and saved the new file as test.rdl.
> >
> >
> > Now when I open the test.rdl report from Report Manager, I see that
> > Iam asked to enter the SQLServer authentication (sa/password). Only
> > after I do the SQLServer authentication, Iam able to view the report
> > in the Report Manager. Why does it ask me so.
> >
> >
> > The thing is Iam playing with the rdl because I need to create reports
> > on the fly (at runtime) in my project requirement. Please share your
> > experiences if you've done something simialar.
> >
> > thanks,
> > Anand Sagar
>

Creating random numbers

Guys, I wanted to create random numbers for some strange purpose using SQL
Server 2000. Even if the numbers are going to repeat its fine. [Pls note I
don't want to use newid() ].
For ex: I want to pass two integer values say, 10, 30 ... now i expect
randoms to be generated between these two numbers. How do to it in SQL
Server. Can any one help me in this?
Regards
SqlBeginnerdeclare @.id int
SET @.id=0
-- create a random sting
SELECT @.id = RAND()*30
SELECT CASE WHEN @.id <10 THEN @.id + 10
WHEN @.id >30 THEN @.id - 10
ELSE @.id END AS Val
Regards
Amish Shah|||declare @.a int,@.b int
set @.a = 30
set @.b = 40
select @.a + cast((@.b - @.a) * rand() as int)|||Check out http://www.drdev.net/article07.htm
Extract from that link for your easy reference:
-- Create the variables for the random number generation
DECLARE @.Random int;
DECLARE @.Upper int;
DECLARE @.Lower int
-- This will create a random number between 1 and 999
SET @.Lower = 1 -- The lowest random number
SET @.Upper = 999 -- The highest random number
SELECT @.Random = Round(((@.Upper - @.Lower -1) * Rand() + @.Lower), 0)
To adjust the upper and lower limit of the random number simply change the
values of @.Lower and @.Upper
Hope this helps!
Best Regards
Vadivel
http://vadivel.blogspot.com
"Omnibuzz" wrote:

> declare @.a int,@.b int
> set @.a = 30
> set @.b = 40
> select @.a + cast((@.b - @.a) * rand() as int)|||Doesn't that formula exclude 999 from the random number pool so that the
highest random number generated will be 998?
Ta,
M. E. Houston
"Vadivel" <Vadivel@.discussions.microsoft.com> wrote in message
news:9CFD8D24-E6A5-42CD-BDFB-363081B22FBE@.microsoft.com...
> Check out http://www.drdev.net/article07.htm
> Extract from that link for your easy reference:
> -- Create the variables for the random number generation
> DECLARE @.Random int;
> DECLARE @.Upper int;
> DECLARE @.Lower int
> -- This will create a random number between 1 and 999
> SET @.Lower = 1 -- The lowest random number
> SET @.Upper = 999 -- The highest random number
> SELECT @.Random = Round(((@.Upper - @.Lower -1) * Rand() + @.Lower), 0)
> To adjust the upper and lower limit of the random number simply change the
> values of @.Lower and @.Upper
> Hope this helps!
> Best Regards
> Vadivel
> http://vadivel.blogspot.com
> "Omnibuzz" wrote:
>|||The first problem is that there are two kinds of random selection from
a set:
1) With replacement = you can get multiple copies of the same value.
This is shooting dice.
This one is easy if you have a random function in your SQL product.
Most of the pseudo-random generators return a floating point fraction
value between 0.00 and 0.9999... at whatever precision your SQL engine
has. The choice of a seed to start the generator can be the system
clock or some other constantly changing value.
SELECT S1.key_col
FROM SomeTable AS S1, SomeTable AS S2
WHERE S1.key_col <= S2.key_col
GROUP BY S1.key_col
HAVING COUNT(S2.key_col)
= (SELECT COUNT(*)
FROM SomeTable AS S3) * RANDOM(seed) + 1.0;
Or you can add a column for this.
CREATE TABLE RandNbrs2
(seq_nbr INTEGER PRIMARY KEY,
randomizer FLOAT -- warning !! not standard SQL
DEFAULT (
(CASE (CAST(RAND() + 0.5 AS INTEGER) * -1)
WHEN 0.0 THEN 1.0 ELSE -1.0 END)
* (CAST(RAND() * 100000 AS INTEGER) % 10000)
* RAND())
NOT NULL);
INSERT INTO RandNbrs2 VALUES (1, DEFAULT);
INSERT INTO RandNbrs2 VALUES (2, DEFAULT);
INSERT INTO RandNbrs2 VALUES (3, DEFAULT);
INSERT INTO RandNbrs2 VALUES (4, DEFAULT);
INSERT INTO RandNbrs2 VALUES (5, DEFAULT);
INSERT INTO RandNbrs2 VALUES (6, DEFAULT);
INSERT INTO RandNbrs2 VALUES (7, DEFAULT);
INSERT INTO RandNbrs2 VALUES (8, DEFAULT);
INSERT INTO RandNbrs2 VALUES (9, DEFAULT);
INSERT INTO RandNbrs2 VALUES (10, DEFAULT);
SELECT * FROM RandNbrs2;
2) Without replacement = you can each value only once. This is dealing
playing cards.
This is trickier. I would start with a table that has the keys and a
sequentially numbered column in it:
CREATE TABLE CardDeck
(keycol <datatype> NOT NULL PRIMARY KEY,
seq INTEGER NOT NULL);
INSERT INTO CardDeck (keycol, seq)
SELECT S1.keycol, COUNT(S2.keycol)
FROM SomeTable AS S1, Sometable AS S2
WHERE S1.key_col <= S2.key_col
GROUP BY S1.key_col;
Now shuffle the deck by determing a random swap pair for all the rows:
BEGIN
DECLARE i INTEGER, j INTEGER;
SET i = (SELECT COUNT(*) FROM CardDeck);
WHILE i < 0
LOOP
SET j = (SELECT COUNT(*) FROM CardDeck) * RANDOM(seed) + 1.0;
UPDATE CardDeck
SET seq = CASE WHEN seq = i THEN j
WHEN seq = j THEN i
ELSE seq END;
WHERE seq IN (i, j);
SET i = i - 1;
LOOP END;
END;
You don't really need j, but it makes the code easier to read.
Biography:
Marsaglia, G and Zaman, A. 1990. Toward a Univesal Random Number
Generator. Statistics & Probability Letters 8 (1990) 35-39.
Marsaglia, G, B. Narasimhan, and A. Zaman. 1990. A Random Number
Generator for PC's. Computer Physics Communications 60 (1990) 345-349.
Leva, Joseph L. 1992. A Fast Normal Random Number Generator. ACM
Transactions on Mathematical Software. Dec 01 1992 v 18 n 4. p 449
Leva, Joseph L. 1992. Algorithm 712: A Normal Random Number Generator.
ACM Transactions on Mathematical Software. Dec 01 1992 v 18 n 4. p 454
Bays, Carter and W.E. Sharp. 1992. Improved Random Numbers for Your
Personal
Computer or Workstation. Geobyte. Apr 01 1992 v7 n2. p 25
Hulquist, Paul F. 1991. A Good Random Number Generator for
Microcomputers.Simulation. Oct 01 1991 v57 n 4. p 258
Komo, John J. 1991. Decimal Pseudo-random Number Generator. Simulation.
Oct 01 1991 v57 n4. p 228
Chambers, W.G. and Z.D. Dai. 1991. Simple but Effective Modification to
a Multiplicative Congruential Random-number Generator. IEEE
Proceedings.Computers and Digital Technology. May 01 1991 v 138 n3. p
121
Maier, W.L. 1991.. A Fast Pseudo Random Number Generator. Dr. Dobb's
Journal.May 01 1991 v17 n 5. p 152
Sezgin, Fatin. 1990. On a Fast and Portable Uniform Quasi-random Number
Generator. Simulation Digest. Wint 1990 v 21 n 2. p 30
Macomber, James H. and Charles S. White. 1990. An n-Dimensional Uniform
Random Number Generator Suitible for IBM-Compatible Microcomputers.
Interfaces. May 01 1990 v 20 n 3. p 49
Carta, David G. 1990. Two Fast Implementations of the "Minimal
Standard" Random Number Generator. Communications of the ACM. Jan 01
1990 v 33 n 1. p 87
Elkins, T.A. 1989. A Highly Random-number Generator. Computer
Language. Dec 01 1989 v 6 n 12 p 59
Kao, Chiang. A Random Number Generator for Microcomputers. OR: The
Journal of the Operational Research Society. Jul 01 1989 v 40 n 7. p
687
Chassing, P. 1989. An Optimal Random Number Generator Zp. Statistics &
Probability Letters. Feb 01 1989 v 7 n 4. p 307
Also, you can contact Kenneth G. Hamilton 72727,177 who has done some
work with RNG's. He has implemented one (at least one) of the best.
"A Digital Dissolve for Bit-Mapped Graphics Screens" by Mike Morton in
Dr.Dobb's Journal, November 1986, page 48.
CMOS Cookbook by Don Lancaster; Sams 1977, page 318.
Art of Computer Programming, Volume 2: Seminumeral Algorithms, 2nd
edition by Donald Knuth; Addison-Wesley 1981; page 29.
Numerical Recipes in Pascal: The Art of Scientific Computing by Press
et al.; Cambridge 1989; page 233.|||dear celko, if you had read the question, you would see that teh
gentleman doesn't mind duplicates, and he wants his results between two
parameters.
your solutions don't solve any of that.
Regarding your second "solution", wouldn't it be if you could do
this set based?
oh. Wait, You can.
make seq real instead of integer.
for the second answer, UPDATE CardDeck
SET seq = RANDOM(seq)
Select * from carddeck order by seq
It is somewhat interesting that there has been no advancement in random
numbers since the year 1992.
regards,
doug

Saturday, February 25, 2012

Creating new instances of SQL Server 2005 Express

Greetings,
I am trying to create new instances of sqlserver express (while the
default SQLEXPRESS is still there). How can i do that?
I'm trying to set up a development and production instance in one
machine. is this a right way to do it?
please advice.
am i doing the right thing? do people really do this? as in separating
development and production with the sql server instance?
On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:[vbcol=seagreen]
> cerebellum,
> Run the SQLEXPRESS installation again, during the installation time setup
> will ask for an instance name., give the new instance name there
> regards
> VT
> Knowledge is power, share it...http://oneplace4sql.blogspot.com/
> "cerebellum" <wilsone...@.gmail.com> wrote in message
> news:1179906209.618347.241560@.p77g2000hsh.googlegr oups.com...
>
|||Hi
Actually , it will be better if you would have a separated server for
developing. Make sure that you have enough memory on the server as each
instance will consume memory and it may hurt performance
"cerebellum" <wilsoneden@.gmail.com> wrote in message
news:1179988261.600407.241950@.a26g2000pre.googlegr oups.com...
> am i doing the right thing? do people really do this? as in separating
> development and production with the sql server instance?
> On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:
>

Creating new instances of SQL Server 2005 Express

Greetings,
I am trying to create new instances of sqlserver express (while the
default SQLEXPRESS is still there). How can i do that?
I'm trying to set up a development and production instance in one
machine. is this a right way to do it?
please advice.cerebellum,
Run the SQLEXPRESS installation again, during the installation time setup
will ask for an instance name., give the new instance name there
regards
VT
Knowledge is power, share it...
http://oneplace4sql.blogspot.com/
"cerebellum" <wilsoneden@.gmail.com> wrote in message
news:1179906209.618347.241560@.p77g2000hsh.googlegroups.com...
> Greetings,
> I am trying to create new instances of sqlserver express (while the
> default SQLEXPRESS is still there). How can i do that?
> I'm trying to set up a development and production instance in one
> machine. is this a right way to do it?
> please advice.
>|||am i doing the right thing? do people really do this? as in separating
development and production with the sql server instance?
On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:
> cerebellum,
> Run the SQLEXPRESS installation again, during the installation time setup
> will ask for an instance name., give the new instance name there
> regards
> VT
> Knowledge is power, share it...http://oneplace4sql.blogspot.com/
> "cerebellum" <wilsone...@.gmail.com> wrote in message
> news:1179906209.618347.241560@.p77g2000hsh.googlegroups.com...
> > Greetings,
> > I am trying to create new instances of sqlserver express (while the
> > default SQLEXPRESS is still there). How can i do that?
> > I'm trying to set up a development and production instance in one
> > machine. is this a right way to do it?
> > please advice.|||Hi
Actually , it will be better if you would have a separated server for
developing. Make sure that you have enough memory on the server as each
instance will consume memory and it may hurt performance
"cerebellum" <wilsoneden@.gmail.com> wrote in message
news:1179988261.600407.241950@.a26g2000pre.googlegroups.com...
> am i doing the right thing? do people really do this? as in separating
> development and production with the sql server instance?
> On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:
>> cerebellum,
>> Run the SQLEXPRESS installation again, during the installation time setup
>> will ask for an instance name., give the new instance name there
>> regards
>> VT
>> Knowledge is power, share it...http://oneplace4sql.blogspot.com/
>> "cerebellum" <wilsone...@.gmail.com> wrote in message
>> news:1179906209.618347.241560@.p77g2000hsh.googlegroups.com...
>> > Greetings,
>> > I am trying to create new instances of sqlserver express (while the
>> > default SQLEXPRESS is still there). How can i do that?
>> > I'm trying to set up a development and production instance in one
>> > machine. is this a right way to do it?
>> > please advice.
>

Creating new instances of SQL Server 2005 Express

Greetings,
I am trying to create new instances of sqlserver express (while the
default SQLEXPRESS is still there). How can i do that?
I'm trying to set up a development and production instance in one
machine. is this a right way to do it?
please advice.cerebellum,
Run the SQLEXPRESS installation again, during the installation time setup
will ask for an instance name., give the new instance name there
regards
VT
Knowledge is power, share it...
http://oneplace4sql.blogspot.com/
"cerebellum" <wilsoneden@.gmail.com> wrote in message
news:1179906209.618347.241560@.p77g2000hsh.googlegroups.com...
> Greetings,
> I am trying to create new instances of sqlserver express (while the
> default SQLEXPRESS is still there). How can i do that?
> I'm trying to set up a development and production instance in one
> machine. is this a right way to do it?
> please advice.
>|||am i doing the right thing? do people really do this? as in separating
development and production with the sql server instance?
On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:[vbcol=seagreen]
> cerebellum,
> Run the SQLEXPRESS installation again, during the installation time setup
> will ask for an instance name., give the new instance name there
> regards
> VT
> Knowledge is power, share it...http://oneplace4sql.blogspot.com/
> "cerebellum" <wilsone...@.gmail.com> wrote in message
> news:1179906209.618347.241560@.p77g2000hsh.googlegroups.com...
>
>
>|||Hi
Actually , it will be better if you would have a separated server for
developing. Make sure that you have enough memory on the server as each
instance will consume memory and it may hurt performance
"cerebellum" <wilsoneden@.gmail.com> wrote in message
news:1179988261.600407.241950@.a26g2000pre.googlegroups.com...
> am i doing the right thing? do people really do this? as in separating
> development and production with the sql server instance?
> On May 23, 3:49 pm, "vt" <vinu.t.1...@.gmail.com> wrote:
>

Sunday, February 19, 2012

Creating indexes (details required)

I need some idea of how SQLServer 2000 creates indexes, particularly
clustered indexes.
I imagine that creating a clustered index is rather similar to defragmenting
a hard disk. Data has to be read from disparate areas, stored "somewhere"
until there is a large enough area and then written to that area in a
contigious manner.
If that premise is correct, where is the temporary storage area? Is it in
the database itself or is it in the TempDB?
The reason I ask is because SQLServer is crashing my machine when it builds
indexes (for details see my posting "SQLServer crashing server!" in
"microsoft.public.sqlserver.server".
Thanks in advance
Griff
When indexes are created the temporary storage for the duplicate ( if
replacing indexes), etc is on the SAME filegroup as the index will be on..
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Griff" <Howling@.The.Moon> wrote in message
news:%232qla4KaEHA.2216@.TK2MSFTNGP10.phx.gbl...
> I need some idea of how SQLServer 2000 creates indexes, particularly
> clustered indexes.
> I imagine that creating a clustered index is rather similar to
defragmenting
> a hard disk. Data has to be read from disparate areas, stored "somewhere"
> until there is a large enough area and then written to that area in a
> contigious manner.
> If that premise is correct, where is the temporary storage area? Is it in
> the database itself or is it in the TempDB?
> The reason I ask is because SQLServer is crashing my machine when it
builds
> indexes (for details see my posting "SQLServer crashing server!" in
> "microsoft.public.sqlserver.server".
> Thanks in advance
> Griff
>

Creating indexes (details required)

I need some idea of how SQLServer 2000 creates indexes, particularly
clustered indexes.
I imagine that creating a clustered index is rather similar to defragmenting
a hard disk. Data has to be read from disparate areas, stored "somewhere"
until there is a large enough area and then written to that area in a
contigious manner.
If that premise is correct, where is the temporary storage area? Is it in
the database itself or is it in the TempDB?
The reason I ask is because SQLServer is crashing my machine when it builds
indexes (for details see my posting "SQLServer crashing server!" in
"microsoft.public.sqlserver.server".
Thanks in advance
GriffWhen indexes are created the temporary storage for the duplicate ( if
replacing indexes), etc is on the SAME filegroup as the index will be on..
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Griff" <Howling@.The.Moon> wrote in message
news:%232qla4KaEHA.2216@.TK2MSFTNGP10.phx.gbl...
> I need some idea of how SQLServer 2000 creates indexes, particularly
> clustered indexes.
> I imagine that creating a clustered index is rather similar to
defragmenting
> a hard disk. Data has to be read from disparate areas, stored "somewhere"
> until there is a large enough area and then written to that area in a
> contigious manner.
> If that premise is correct, where is the temporary storage area? Is it in
> the database itself or is it in the TempDB?
> The reason I ask is because SQLServer is crashing my machine when it
builds
> indexes (for details see my posting "SQLServer crashing server!" in
> "microsoft.public.sqlserver.server".
> Thanks in advance
> Griff
>

Creating indexes (details required)

I need some idea of how SQLServer 2000 creates indexes, particularly
clustered indexes.
I imagine that creating a clustered index is rather similar to defragmenting
a hard disk. Data has to be read from disparate areas, stored "somewhere"
until there is a large enough area and then written to that area in a
contigious manner.
If that premise is correct, where is the temporary storage area? Is it in
the database itself or is it in the TempDB?
The reason I ask is because SQLServer is crashing my machine when it builds
indexes (for details see my posting "SQLServer crashing server!" in
"microsoft.public.sqlserver.server".
Thanks in advance
GriffWhen indexes are created the temporary storage for the duplicate ( if
replacing indexes), etc is on the SAME filegroup as the index will be on..
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Griff" <Howling@.The.Moon> wrote in message
news:%232qla4KaEHA.2216@.TK2MSFTNGP10.phx.gbl...
> I need some idea of how SQLServer 2000 creates indexes, particularly
> clustered indexes.
> I imagine that creating a clustered index is rather similar to
defragmenting
> a hard disk. Data has to be read from disparate areas, stored "somewhere"
> until there is a large enough area and then written to that area in a
> contigious manner.
> If that premise is correct, where is the temporary storage area? Is it in
> the database itself or is it in the TempDB?
> The reason I ask is because SQLServer is crashing my machine when it
builds
> indexes (for details see my posting "SQLServer crashing server!" in
> "microsoft.public.sqlserver.server".
> Thanks in advance
> Griff
>