| Dinesh 的个人资料Dinesh's Blog ...日志列表网络 | 帮助 |
|
4月23日 Indirect Configuration and multiple SSIS packagesOne of the disadvantages with direct configuration (configuration location is hard-coded in the package) is, the location of the configuration file should be same as it was at the design time. For example, if you use the configuration file as D:\MyConfigFile\PackageConfiguration.dtsConfig at the design time, SSIS package expects the config file from the same path once it is deployed. One way to over some this issue is, disable the configuration from the package and compile, and assign the configuration file explicitly at run-time. Other way is, Indirect Configuration. Indirect configuration can be simply implemented by setting the configuration location in the envoirnment variable. The configuration file can be deployed to any location. The SSIS package looks for the envoirnment variable for the location of the config file. 4月17日 My SP does not use the index I addedI am sure that you have experienced this issue. You might have seen that the content of the SP works fine (within the expected time-frame), but not the SP. There are many reasons for this, but I recently noticed this issue in one of the SPs which I examined. Let me share the issue and fix with you, it might be helpful WITH your work. Assume that the below table contains 100000 (from the year 1753) records and you try to get some records by using the SP GetTestData. CREATE TABLE TestTable (ID int IDENTITY(1,1) PRIMARY KEY, Date datetime, String varchar(1000)) CREATE PROC GetTestData @number int DECLARE @NewDate datetime END Note that we can add "DATEADD(month, @number, getDate())" to the WHERE condition without any problem but presume that the formula is much more complex than this and cannot be added to the "WHERE" condition directly. Now let's try to get some result-sets. If I need to get records for last 10 months, I will be executing the below query; EXEC GetTestData -10 If you have enabled "Include Actual Execution Plan" and "I/O", you may notice that SQL Server has not used the index which we had added and uses more logical reads than we expected (14340). DECLARE @NewDate datetime END Now we can see that; EXEC GetTestData -10 is executed by using the index we added and with the time we expected and less page reads. So, if you face this issue, measure it, understand the requirement, and use OPTIMIZE FOR. 4月7日 First Sri Lanka SQL Server User Group MeetingThe very first local SQL Server User Group Meeting held on 5th, Thursday. The first session was done by me, focusing on SSIS fundamental stuff and the second session that focused on BI was done by Gogula. My concentration on the session was interrupted frequently by my family (my mobile started ringing, ringing, ..) since my daughter was very sick. Unfortunately I had to leave the meeting early (I really missed the Gogula's presentation) and rushed her to the hospital. She is still in the hospital but getting better. 4月2日 CodePlex/SqlServerSamples and BOL new search functionalityIf you are looking for SQL Server samples and Community projects from Microsoft, SQL Communities and SQL Server experts, CodePlex for SQL Server Samples is the site you have to look for. The content of the site seems very useful for SQL Server DBAs, engineers and whoever involve with SQL Server stuff. Though the most areas in the site are not filled with info, have a look, it will definitely give what we expecting. The new searching functionality has been added for BOL; Scoped search that give you the rich result-set for the search you make. Go to the site http://search.live.com/macros/sql_server_user_educ... and see how useful it is. |
|
|