That's what I was thinking exactly, however, this seem to completely fill
the logsegment in tempdb unless we make it the size of this enormous table
we got. This happens during the SELECT INTO FROM src_table ORDER BY step.
"Leonid Gvirtz" <***@yahoo.com> wrote in message news:670903cc-2e4d-47ae-85ff-***@d5g2000yqm.googlegroups.com...
Hi Axel
Did you try WITH SORTED_DATA option for creation of your clustered
index? If not - then it may be the way. Add ORDER BY clause according
to the clustered index fields to your SELECT INTO statement. Then, you
will be able to skip the data copying during the clustered index
creation by using WITH SORTED_DATA option since the data in the
resulting table is already sorted. See this link for more details:
http://infocenter.sybase.com/help/topic/com.sybase.infocenter.dc36272.1502/html/commands/X58868.htm#X24774
Hope it helps
Leonid Gvirtz
http://www.gvirtz-consulting.com
Post by AxelSELECT INTO does look like the fastest method.
But in our case, for instance, we have a table with approx. 150M rows. While
SELECT INTO took roughly 3 hours, it's the subsequent build of clustered
index that times out.
Is there a way to boost that, maybe run something in parallel?
Partitioning
this table is not an open option at this time, since we are prohibited to
change the model by the vendor.
Post by TesterBypassing the disk.
Something like a batch select into dest_db..dest_table from
src_db..src_table or insert select.
Anything that does not involve excessive logging and storing bcp output on
disk.
Hi
Assuming that you need to move the data between different dataservers,
you can use CIS for this purpose. Create a proxy table in the
destination database that points to your source table in the source
dataserver. Then, you will be able to run SELECT INTO statement into a
new table in the destination dataserver from the proxy table with
minimal logging. You may want to tune some CIS-related parameters on
source and destination dataservers for better performance, such as
"cis packet size", "cis bulk insert array size", "cis cursor rows"
etc.
Hope it helps
Leonid Gvirtzhttp://www.gvirtz-consulting.com