Quantcast
Channel: SQL Server Integration Services forum
Viewing all 24688 articles
Browse latest View live

How to use checksum to compare file sizes

$
0
0

This is my first time using checksum, and I'm not sure how to proceed this.  Can someone help please?

 

I've a dtsx package which daily downloads multiple files from an ftp server.  The files have multiple extensions (*.done, *.txt, *.gz, etc.)  I've no problem downloading these files to my server.  However, I need to check the file sizes and checksum.  One of the file that I download is CompleteFile.done; this file contains all other files information and has following data:

 

CompleteFile generates at 09/16/2008 1:00 PM

FileName          SHA-CheckSum                                                         Size

File1.gz            cf0ae9bf1cb661f080e27852d6f4e1a483360084               637504942

File2.gz            d87f8a91eb15524f0988a1d8f3ad071e3766b2d5              7712174

...etc.

 

I was trying to save the .done file as .txt and using Flat File Source task to read the data but I was not able to; that's one problem.  Another problem is, how can I use the checksum from this file to validate with the files I already extracted?

 

Any suggestion is appreciated.

 

Thanks in advance,

 

-Ash


sql agent

$
0
0

hi,

if schedule job , that will fire ssis ,

now in ssis i have wmi event task,that will constantly look for the fiel in some particular folder, so if the file is not there,will my package gets failed.

second option:

insetead of wmi event task, can i use script ,that will look for the file in particular folder,if it is there it will give that name to data flow flat file soure,if not it will just exit from package.

please guide me.

i dont knwo script to see wheather w have file inthe folder or not

CHECKSUM for Delta Process in SSIS(Incrmental Load)

$
0
0

Hi All,

I`m using CHECKSUM in SSIS for Delta Processing. Please suggest me if any issues with CHECKSUM for the following implementation process.

Requirement: develop a package to Load data from one sql server instance table to another instance table. when the package runs for second time, it should only load the new trecords and updates the destination if any existing records modified in source.

My solution:

step 1: I`m adding one column in destination table which will be filled up with CHECKSUM(*) from source table. i'm comparing this checksum value with source every time package runs to identify the new records and updated records from source.

step 2: Delete the records from destination if any records modified at source

step 3: Apply the LEFT JOIN on Source to destination and inserting the records from source to destination.

version: SQL SERVER 2008 R2 ,2008 BIDS

Please suggest me is there any performance issues/functionality issues.

 

 

 

How to prevent SSIS from checking connection objects on a deployed package?

$
0
0

Hi, 

I am working on a project that uses SSIS to load a data warehouse, and I would like to know if there is a way to prevent SSIS from checking/validating the connection objects once the solution is deployed. I have tried to google for an answer and to search through this forum but I failed to find any similar examples. 

We have created a SSIS project for each individual source, and individuals packages for each table/file to be loaded. Each project has also a "full load"-package that runs a "Execute Package Task" for each of the other packages. On top of this there is an SSIS_Fullload project with a single package that executes all fullloads packages within the solution. These full load packages are organized in to work in the following manner:

  1. Script task that checks that all connection objects are available by looping through each connection in the Dts.Connections and trying to acquire the connection. If one of the connections fail the ConnectionsAreOk-variable is set to false.
  2. Depending on the status of the ConnectionsAreOk the following happens:
    False:Log error and send email alert
    True: Continue to perform SSIS logic within a Sequence Container.

Everything works fine when I run the solution on my computer. However, once I deploy it to a SQL server instance in my own computer SSIS tries to validate the connections and fails completely. Before even attempting to run the packages. I am using a configuration file that is accessed though an Environmental Variable. Since it is all on the same computer everything is identical. One of the connection strings is deliberately set to point to an nonexistent server to test that everything works as intended.

My question is therefore, how can I force SSIS not to validate my connections? The validation causes an error on the fullload preventing the execution of other error free fullload-packages.  I tried to set theDelayValidation=True but it seems to only affect object on design time. 

Performing mathematical operations on data before importing into SQL using SSIS?

$
0
0

Hello, Is it possible to multiply a number of rows by a constant before importing into a SQL Server database using SSIS?

For example, I have a temperature table in my SQL database that  contains a decimal datatype (ie -10.5 would represent -10.5 degrees celsius). I have been given a flat file in which temperature data is present but, it is given in the following form -00105 (this is a string). After the flat file source imports the test file I have a data conversion block that converts -00105 to a decimal number (I am assuming this will transform -00105 to -105.00, although I haven't run this yet so not sure it will work)...Then I want to multiply this number by 0.1 to get the value of -10.5......what can i use to do this? Every single piece of temperature data needs to be multiplied by 0.1 before being imported into the database.

Thanks


Index droping problem in SSIS package?

$
0
0

Hi All,

I have one ssis package. After load the staging data I am creating index in one column. I am dropping the index end of package. But sometimes after create the index if I got any error I need to re run the package, already index is created so that’s why once again I will get a error. So that purpose drop index statement I used before create index sqltask.If the first time package runs the table don’t have index. If the table have index it will drop the index otherwise it will skip that task. I used below code. But I am getting the error index is not dropped properly.

IF EXISTS (SELECT name FROM sys.indexes WHERE name =

 N'IND1_TRAN_DT

')

 DROP INDEX IND1_TRAN_DT

 ON SLS_STNT_DTL_STGNG;

 

Thanks

CMK

Reading a Spreadsheet with Text in between Data Rows

$
0
0

hello!

I have a new challange. I have an Excel Spreadsheet that has several rows of data which I need to read with an SSIS component and then two rows of text such as

Marshall County Treasurer

RE - Real Estate Tax

and then maybe 10 more rows of data and then 2 rows of text (Different from those above)

and so forth and so on. Does anyone have any guidence on how to proceed from a high level? I have been trying to figure this one out from a "how to" standpoint. I can implement it if anyone know of any examples or suggestions. I need to import this data into a Sql Server...

Thanks!
Mike


Mike Kiser

Using XML as Input Parameter Reslts in "Invalid at the top level of the document"

$
0
0

In an Execute SQL Task i'm using a stored procedure with one input parameter. The parameter is defined as varchar(max), but the expectation is that valid xml would be passed in. The stored proc subsequetly opens the xml. When the xml string is relatively short, everything works fine. But for longer XML strings, the Execute SQL task fails. One of the messages is "Invalid at the top level of the document". When I capture the command via a trace and run it directly from SSMS, everything runs fine. There are more details, but I'm not sure what is important.


Loading data from a column in a table to a flat file with commas

$
0
0

Hey,

I have a table with 1 column (imported from a flat file, trying to see If i can do some scrubbing), which has data like this:

#

##

Inum=25690

Stock=New

#Start

123,234,567

qwd,qas,qsd

#End

##

#

Can I load this file in to my flat file? I want the results to look like this:

#,##,INum=25690,Stock=New

package is not ruuning

$
0
0

hi,

i am scheduling job to run ssis package on particualr time,

when i see job monitor is succeeded ,but my package load data into table ,once it runs,i am nto getting any dat ain the table

error handling

$
0
0

hi,

this is my first time i need to do error handling , below is my package and i am getting file every month,if i redirect rows from flat file or oledb ,

do i need to put in flat file or in table.

what is the best practice, how can i deal it with event  handle

 

import csv file use ssis why 04-2302 change to Apr-02

$
0
0
import csv file use ssis why 04-2302 change to Apr-02

SSIS package in SQL task fails - Excel class not registered

$
0
0

Hello all,

I have perused the forums and seen many similar issues but have yet to see a solution that works for me.

Basically, I have an SSIS package that imports to SQL 2008 R2 from an Excel 2007 spreadsheet. When I run the package manually from SSMS it executes successfully (I have tried locally and RDP'd to the Server with same results). In short, here is the error: "The requested OLE DB provider Microsoft.ACE.OLEDB.12.0 is not registered."

Excel is not installed on the server where I am trying to run the Job. Here is the unaltered command line from inside the job:

/DTS "\MSDB\ImportCheckSchedule" /SERVER blue201  /X86  /CHECKPOINTING OFF /REPORTING E

Any help would be greatly appreciated!

FULL ERROR MESSAGE:

Executed as user: PBHC\SQLAgentSVS. Microsoft (R) SQL Server Execute Package Utility Version 10.50.2500.0 for 32-bit  Copyright (C) Microsoft Corporation 2010. All rights reserved.   Started:  9:39:19 AM  Error: 2012-11-14 09:39:25.10    Code: 0xC0209302     Source: ImportCheckSchedule Connection manager "Excel Connection Manager"    Description: SSIS Error Code DTS_E_OLEDB_NOPROVIDER_ERROR.  The requested OLE DB provider Microsoft.ACE.OLEDB.12.0 is not registered. Error code: 0x00000000. An OLE DB record is available.  Source: "Microsoft OLE DB Service Components" Hresult: 0x80040154  Description: "Class not registered". End

Error  Error: 2012-11-14 09:39:25.11     Code: 0xC020801C    Source: Import Schedule Source - Dates$ [1]     Description: SSIS Error Code DTS_E_CANNOTACQUIRECONNECTIONFROMCONNECTIONMANAGER. The AcquireConnection method call to the connection manager "Excel Connection Manager" failed with error code 0xC0209302. There may be error messages posted before this with more information on why the AcquireConnection method call failed. End Error  Error: 2012-11-14 09:39:25.12    Code: 0xC0047017     Source: Import Schedule SSIS.Pipeline    Description: component "Source - Dates$" (1) failed validation and returned error code 0xC020801C. End

Error  Error: 2012-11-14 09:39:25.12     Code: 0xC004700C    Source: Import Schedule SSIS.Pipeline     Description: One or more component failed validation.  End Error Error: 2012-11-14 09:39:25.12     Code: 0xC0024107    Source: Import Schedule      Description: There were errors during task validation. End Error  DTExec: The package execution returned DTSER_FAILURE (1). Started:  9:39:19 AM  Finished: 9:39:25 AM Elapsed:  5.188 seconds.  The package execution failed. The step failed.

not seeing anything on sysssislog

$
0
0

hi,

i am having log provider in sql server table.

when i run the package ,it run successful,but cant see any log in sysssislog

what should i do

DTS does not populate Excel

$
0
0

I am using SQL 2000 DTS to populate an excel spreadsheet. this report runs daily and works most of the time.

All transforations have work flows set to success and only one trasformation can run at a time.

lately the DTS package appears to have skipped a transformation in that it runs all the trasformations but one of them does not poplulate the excel spreadsheet and it does not give an error.

the error log shows that the step succeeded but the data was not sent to the excel sheet and the package kept going on to the next step.

Step 'DTSStep_DTSDataPumpTask_29' succeeded
Step Execution Started: 11/14/2012 11:05:55 AM
Step Execution Completed: 11/14/2012 11:06:07 AM
Total Step Execution Time: 11.625 seconds
Progress count in Step: 2

I susspec this may be a memory issue but cannot figure out how to track this when it happens.

I can rerun the report and the job runs fine.


How to create Dynamic SSIS Package

$
0
0

Hi Friends

I AM NEW TO SSIS

Please help me 

How to create Dynamic SSIS Package

Retrieving the COM class factory for component with CLSID {...} failed due to the following error: 80070005

$
0
0
Hi All,
This error has had me stumped for a week. I have read numerous forum posts from all sources and tried most of the suggestions to no avail.
Please note that I can run the DTSX package on the production server manually quite successfully. It produces an XLS file.
When called from ASP.NET however, it fails.

Additional error information:
"ASP.NET is not authorized to access the requested resource."
"Consider granting access rights to the resource to the ASP.NET request identity. "

There is no ASP.NET user nor a NETWORK SERVICE user on the Server!

The CLSID {BA785E28-3D7B-47AE-A4F9-4784F61B598A} refers to in the registry:

Default  REG_SZ C:\Program Files\Microsoft SQL Server\100\DTS\Binn\DTS.dll

Assembly REG_SZ Microsoft.SqlServer.DTSRuntimeWrap, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91

Class    REG_SZ  Microsoft.SqlServer.Dts.Runtime.Wrapper.ApplicationClass

Error: 80070005 usually refers to access denied.
8027758069
Environment:
Windows Server 2008 R2 with Service Pack 1 64-bit
Microsoft SQL Server 2008 R2 (RTM) - 10.50.1600.1 (X64)
Microsoft Visual Studio 2008 Version 9.0.30729.4462 QFE
Microsoft .NET Framework Version 3.5 SP1
Parallels Plesk Panel 11.0.9 for Windows

I have created an ASP.NET web page that calls a DTSX package as follows:

Line 11:   Private Sub btnExecute_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnExecute.Click
Line 12:     Dim app As New Application
Line 13:     Dim package As New Package
Line 14:     Dim filename As String = ""
Line 15:    Dim csvFileName As String = ""
Line 16:
Line 17:    Try
Line 18:      filename = Server.MapPath("/dtsx/MakeNewOrdersXLS.dtsx")
Line 19:
Line 20:      '***Load DTSX
Line 21:      package = app.LoadPackage(filename, Nothing)

The error is thrown on line 12: Dim app As New Application
Of course this application runs perfectly on my development machine:
    Windows 7 32-bit Pro with SP1
    Visual Studio 2008 with SP1
    .NET Framework 3.5 SP1
    SQL Server 2008 Standard 32-bit
But it doesn't run on the production web server as specified under Environment at top. Note that the Website resides on the same
server that the SQL Server database is on. It is a leased Dedicated Web Server that uses Plesk to provision the web sites.
    
Solutions that I have tried:

1. The application pool that the website runs under uses Identity SRV1\IWPD_1 (an identity created by PLesk). I have added that user
to the Local Administrators group. That did not solve the problem. There is no Active Directory domain. SRV1 is the name of the local server.

2. I have tried using identity impersonation with the same ID/PWD that I use to log into the server via RDP, with which I can easily
run the DTSX package manually without a problem.
    <identity impersonate="true" userName="SRV1\admin_login" password="RO_##_$$_ex"/>
That allows the package to return "Success" but NO XLS file is produced!

3. I am using the References to the assemblies found in the GAC.
    <add assembly="Microsoft.SqlServer.DTSRuntimeWrap, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>
    <add assembly="Microsoft.SqlServer.ManagedDTS, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>
I have tried giving Read_Write_Execute rights to the C:\Windows\Assembly folder to the Identity "SRV1\admin_login", but even though I am
 logged in to the server as an Administrator (via RDP) I am not allowed to propagate those rights to the assemblies in the GAC.

4. I have tried to change those references to the same named assemblies in the C:\Program Files\Microsoft SQl Server\100\SDK\Assemblies
folder, but for some reason they do NOT get written to Web.config! I was going to give the Identity "SRV1\admin_login" rights to those assemblies directly.
But if the references are not accepted by Visual Studio, then what is the use of that?

Anyone have any ideas? Any help will be appreciated.

How to give value to field form other fields used in SSIS trasformation?

$
0
0

Hi All,

I have 36 fields(SINGLE_PREM_X, X = 1 to 36) in output file(.txt file) to create. All fields contain some numeric value. Few of them(12 fields) have to map with input fields from the table(which is already available/created) and rest of them(24 fields) I have to set 0 values in derived column in SSIS.

I have one more field name (NO_SINGLE_PREM) to get in output file and I have to set(give) this field like "This is equal to the number of array elements (SINGLE_PREM_X) filled with a value greater than 0."

Please tell me how can I get integer value for field name NO_SINGLE_PREM.

In my SSIS package, I have OLE DB source, Derived column and flat file destination set up.  

Thanks for the help in advance.


Vicky



upload file

$
0
0

hi,

i have .dat file ,when i upload the file it shows data like this

what should i do, i can upload using import export ,but the thing is i need to perform some validation

Package Validation Error (Package Validation Error) - cannot convert between unicode and non-unicode string data types.

$
0
0

Hello,

This application looks straight forward enough but when I try to run a package to test a simple import of 2 columns from a flat file to a table, I get the following error

Package Validation Error (Package Validation Error)

===================================

Error at Data Flow Task [OLE DB Destination [601]]: Columns "EMPLOYEE_BAR_CODE" and "EMPLOYEE_NO" cannot convert between unicode and non-unicode string data types.

Error at Data Flow Task [OLE DB Destination [601]]: Columns "EMPLOYEE_DISPLAY_NAME" and "EMPLOYEE_NAME" cannot convert between unicode and non-unicode string data types.

Error at Data Flow Task [SSIS.Pipeline]: "component "OLE DB Destination" (601)" failed validation and returned validation status "VS_ISBROKEN".

Error at Data Flow Task [SSIS.Pipeline]: One or more component failed validation.

Error at Data Flow Task: There were errors during task validation.

 (Microsoft.DataTransformationServices.VsIntegration)

------------------------------
Program Location:

   at Microsoft.DataTransformationServices.Project.DataTransformationsPackageDebugger.ValidateAndRunDebugger(Int32 flags, DataWarehouseProjectManager manager, IOutputWindow outputWindow, DataTransformationsProjectConfigurationOptions options)
   at Microsoft.DataTransformationServices.Project.DtsPackagesFolderProjectFeature.ExecuteTaskOrPackage(ProjectItem prjItem, String taskPath)

here is my table schema for the 2 columns

CREATE TABLE [dbo].[MY_EMPLOYEES](
    [MY_EMPLOYEES_KEY] [int] IDENTITY(1,1) NOT NULL,
    [EMPLOYEE_NO] [nvarchar](50) NULL,
    [EMPLOYEE_NAME] [nvarchar](50) NULL,
    [DATABASE_MAINTENANCE] [bit] NULL,

....

What could be wrong?

Viewing all 24688 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>