| bio | website | |
|---|---|---|
| location | Arkansas | |
| age | 32 | |
| visits | member for | 1 year, 5 months |
| seen | 14 hours ago | |
| stats | profile views | 21 |
Data Warehouse Specialist / Database Developer / Database Administrator
|
Jan 10 |
comment |
How do I add minutes to a time data type? +1 @Aaron Alternatively you can convert StartTime and TimeToAdd to datetime and then add. Converting TimeToAdd will be very messy when the minutes are > 59. DATEADD is the best solution. |
|
Jan 10 |
comment |
Remote queries and linked servers So you're suggesting a RBAR update? Using OLE DB command for UPDATE = RBAR |
|
Dec 19 |
comment |
Bulk Data Loading and Transaction Log Good deal. While the Checkpoint will get the table loaded, getting a minimally logged bulk insert should be a significant performance boost. The TABLOCK should get it done. |
|
Dec 19 |
comment |
Bulk Data Loading and Transaction Log I believe I see the issue. Not sure how I looked this over. The bulk insert isn't using the tablock option. msdn.microsoft.com/en-us/library/ms190422.aspx TABLOCK is the second bullet of the pre-requisites. |
|
Dec 19 |
comment |
Bulk Data Loading and Transaction Log Did you split the procedures up? Which one is popping the log? The bulk insert or the merge? |
|
Dec 12 |
comment |
Why is my database stuck in the Restoring state? Just an fyi, you can check the status of a database restore and get an estimated amount of time for it to complete. Not sure what's actually going on, but would be interested to see what the query results are. The query can be found here: sqldbadiaries.com/2010/09/07/… Just change the where clause from B.COMMAND LIKE '%BACKUP%' to B.COMMAND LIKE '%RESTORE%' |
|
Dec 12 |
comment |
Why is this key lookup required? +1 Good catch @Roji I looked right over that. Still 1216 is well below 10 million so there is still a statistics mismatch. Also, OP stated in the comment that updating stats resolved the issue. |
|
Dec 11 |
comment |
Why is this key lookup required? Have you updated statistics lately? Estimated Number Of Rows is 1 while Actual Number Of Rows is 10,259,536... Dated stats can lead to bad query plans (insufficient memory allocated for joins and sorts, bad join algorithm choices...). |
|
Dec 5 |
comment |
error in Execute SQL Task with parameter What type of connection manager is the database connection defined as? OLEDB? ADO.Net?... |
|
Dec 3 |
comment |
Is the SQL Server Express memory and CPU limit per instance? Not following either. This seems somewhat ambiguous. The document says 1 GB per database engine. I believe each service/instance would count as a separate engine, so they'd each get 1 GB. Roy, do you have any other references on this? |
|
Nov 24 |
comment |
What is the fastest way to export a table to a text file I see the links and fully agree. But most of the optimization points are for loading data into sql server. I've yet to see any facts related to bcp being faster than a streamwriter or filestream CLR solution when writing sql data to a flat file. |
|
Nov 17 |
comment |
Average Time to Load 1.2 million records from Oracle INTO SQL SERVER 2008R2 What recovery model is the destination database in? This seems unreasonably slow. Post the table definition for the destination table. It sounds like either your table is really wide, you're in the full recovery model, you have some heavy transformations in the data flow task, the destination table has a clustered index which is forcing the data to be sorted before insert, or a mixture of the above. Additionally, disk speed or network throughput could be part of the issue. Alot of unknowns here. |
|
Nov 2 |
comment |
Why is my CPU usage increase after setting database to read-only on SQL Server 2008 R2 What are you doing to copy the database? Are you doing a full refresh of each table? Are you doing any index maintenance or updating stats before setting the database to read-only? Does your denormalized design contain the appropriate covering indexes? |
|
Nov 1 |
comment |
TempDB size issue after applying Indexes +1 SSMS actually has a built in report which will show when the data file(s) grew and by how much. In SSMS, Right click tempdb->Reports->Disk Usage . Any autogrowth since the last service start should show up in the report. |
|
Oct 31 |
comment |
PAGE compression in SQL Server effect on running queries Is the table partitioned? |
|
Oct 31 |
comment |
Partitions and Indexes, in which cases should be used +1 @Remus Partitioning should only be used after careful evaluation. See Kendra Little's blog on whether to partition: brentozar.com/archive/2012/03/… If you don't know what you're doing with partitioning, performance will go south quickly. |
|
Oct 31 |
comment |
UDF performance suddenly degraded Just curious. Have you tried "SELECT from @TableVar OPTION(RECOMPILE)"? Table variables are known to get an estimated row count of 1 due to not having statistics. Using OPTION(RECOMPILE) may help with the estimated row count on the select statement. sqlservercentral.com/blogs/dave_ballantynes_blog/2011/12/02/… |
|
Sep 13 |
comment |
Why does a VIEW with a CLUSTERED index not use the index? +1 Good catch @Damien_The_Unbeliever |
|
Aug 25 |
comment |
Is it possible to get SQL Server 2008 to download a file from a URL +1 Remus. Great advice. I just wish that you'd suggested an appropriate way to do this. Seems more like a comment than an answer. |
|
Aug 24 |
comment |
How do you roll up header-level values on a fact table with line-item granularity? +1 This will work. You can even get rid of the Shipping Amount column. |