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

Importing Data into SQL Azure

$
0
0

I am trying to import a million record table into SQL Azure, it imports fine in the local SQL and then i create the same table in Azure with a Clustered Index, but during the data import i get the following series of errors:

·Error 0xc020844b: Data Flow Task 1: An exception has occurred during data insertion, the message returned from the provider is: A transport-level error has occurred when receiving results from the server. (provider: TCP Provider, error: 0 - An existing connection was forcibly closed by the remote host.)
 (SQL Server Import and Export Wizard)
 

·Error 0xc0047022: Data Flow Task 1: SSIS Error Code DTS_E_PROCESSINPUTFAILED.  The ProcessInput method on component "Destination - Consumer" (52) failed with error code 0xC020844B while processing input "Destination Input" (55). The identified component returned an error from the ProcessInput method. The error is specific to the component, but the error is fatal and will cause the Data Flow task to stop running.  There may be error messages posted before this with more information about the failure.
 (SQL Server Import and Export Wizard)
 

·Error 0xc02020c4: Data Flow Task 1: The attempt to add a row to the Data Flow task buffer failed with error code 0xC0047020.
 (SQL Server Import and Export Wizard)
 

  • Error 0xc0047038: Data Flow Task 1: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED. The PrimeOutput method on component "Source - Consumer" (1) returned error code 0xC02020C4. The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing. There may be error messages posted before this with more information about the failure.

My destination settings are:

NameValue
Destination.Net Framework Data Provider for SqlServer
EncryptTrue
Integrated SecurityFalse
Password(Enter the SQL Azure administrator password)
TrustServerCertificateTrue
User ID(Enter the SQL Azure administrator username in the format of [username]@[sqlazureservername])
Data Source(Enter the FQDN of your SQL Azure Server)
Initial Catalog(Enter the database name where you want to insert data to)


Send e-mail if SSAS cube is down

$
0
0

Hi,

Sometimes, cube goes down for whatever reason. Is there a way to create an SSIS pkg to check for cube's status every 5 minutes or so and if it finds that cube is down, send e-mail?

Thanks

percentage in excel

$
0
0

Hi,

I'm trying to import data from excel into sql db. I have an excel source and an UNPIVOT operator and finally the OLEDB Destination. The incoming data is in the following format pic(2) and in the pic (1) after using the UNPIVOT operator and loading the data into sql db. How can i see the same exact format as in excel in my table in the sql db?If you see in the excel for 10AM i have the valu as 200.00% but when i load it into the table i can only see the value 2. The data type for UTILIZATION is FLOAT. Please need help.

Thanks

Anyone deeply understand the BufferWirePacket of PipelineBuffer?

$
0
0

Hi All,

To most of my customers, SSIS is too heavy to use. So I'm writing my own Integration Services based on my understanding of SSIS and using Silverlight as its UI.

The progress is good currently, but I met some design problems, the most critial one is how to understand the role of BufferWirePacket in PipelineBuffer Constructor and how MS realize this under that IntPtr.

MSDN only provides the following article for this:

http://msdn.microsoft.com/en-us/library/microsoft.sqlserver.dts.pipeline.pipelinebuffer.pipelinebuffer(v=sql.110).aspx

But it doesn't constain enough useful message for "BufferWirePacket", because it's "IntPtr", but I really believe it's the core of the magic of SSIS, it helps PipelineBuffer to control the producers-consumers model.

Anyone can help me?


Regards, Nighting Liu

SSIS 2005: date being loaded with wrong century

$
0
0

Hello,

I am using ssis 2005 to load a .csv file into sql server 2005. it is pipe (|) delimited.

The dates in this file have format:   DD-MON-YY

I am using a script task (transformation).

for example: this date   28-JUL-21

I am converting the MON to MM.

(example:  JAN to 01, FEB to 02, etc...)

the result string would be:   07/28/21.

when I insert the field, the date is: 2021-07-28

it should be 1921-07-28

it does not do this for all dates, just some of them.

Why does it do this?

How can I fix this issue?

Please help.

Thanks !!!


Connection manager :changes are not saved after edit ,the package still retains the old server name

$
0
0

I copied a prod pkg to my local machine and opened it in BIDS .The package had a oledb connection to sql server .I wanted to chnage it and point it to my local machine sql server.But whenever I make changes in the connection manager the settings are not saved .

bids 2008r2

What might be the issue?


Mudassar

loop over all variables to change an variable property

$
0
0

I'm currently working on an package template for my developers.

I have build an OnValueChanged - EventHandler.  ( i use the great example from Eric Wishdal: http://social.msdn.microsoft.com/Forums/en/sqlintegrationservices/thread/a1987e67-37d1-4998-a978-9930d029455c)

But now i want to get shure that all variables in the package have the property: RaiseChangedEvent = True

I currently hang on an loop over all variables in the package.

Because i want to build this in an template i didn't know what variables the developers use in the future.

Does anyone have an example for such an loop?

greetings

selcer

question regarding ssis 2012 lookup transformation (cache)

$
0
0

I have a few tables that has over 200+ million rows.  I would like to perform an incremental load to these tables.  It is currently a flush and fill method which as you know is not something that is desirable.

each table is within its own data flow task.  And for each data task, I would like to have a lookup transformation in between the source and destination.  I tried using the partial cache and apparently, i'm stuck at 4096 (~4GB) for 64bit, which is not enough for a table w/ 200+ million rows.  I would like to use Full cache instead but I have a couple questions about that

1. is full cache using SQL Buffer Cache or cache reserved outside of SQL?

2. does full cache release itself after the data task flow task is done or does it hold onto that cache until the entire pkg is done?

Thanks




SSIS 2012 Package Failing at Script task

$
0
0

Background:
I have a project done in Integration Services 2012. The purpose of the SSIS package is to replace the Data Driven Subscriptions provided by the more expensive versions of SSRS. An ASP.NET web application is the front end, and has multiple departments with email lists associated to each department... The SSIS package checks to see if there is any data for the report, so the email doesn't contain an empty pdf. Then it compiles the "To" string with the emails specific to that department.

Then in the script task it performs two tasks:
1) Cleans up the network share of all pdf files
2) Connects to the SSRS web service and generates the report that is then exported to pdf in the network share directory.

Finally, if the pdf exists, the package emails it to the list of emails generated in a string. So basically it is a drawn out way to replace the Data Driven Subscriptions that certain versions of SSRS offer.

Problem:
The problem is with one server in particular. I have this package installed on 4 different SQL Server instances and working 100%, every morning at 8AM it runs without error or issues. However, I have to put it into production on an instance that refuses to execute it successfully. The package sends out an email on failure, so I added a variable to the script task to catch the exception and include it in the failure email. I get an error when attempting to access the network share directory, and when attempting to access the SSRS service. As I said before, this package works everywhere but at this location. I cannot debug from my box, because the package executes perfect from Visual Studio. So I turn to the SQL Server community. Below are my two exceptions and my script task code. I cannot help but thinking the SQL Server is missing something, maybe a library required to execute the Script Task. I have added the domain account that is used by the SQL Service to the SSRS server and the network share with full permissions, and I have even tried .NET Impersonation in the script task, and while the Impersonation works, the script task still fails with the same error. 

Errors:

System.IO.IOException: Logon failure: unknown user name or bad password.

   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileSystemEnumerableIterator`1.CommonInit()
   at System.IO.FileSystemEnumerableIterator`1..ctor(String path, String originalUserPath, String searchPattern, SearchOption searchOption, SearchResultHandler`1 resultHandler)
   at System.IO.Directory.GetFiles(String path, String searchPattern, SearchOption searchOption)
   at ST_489cafcbe82c45eb9f591b14e21080ff.ScriptMain.Main()

System.Net.WebException: The request failed with HTTP status 401: Unauthorized.
   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at ST_489cafcbe82c45eb9f591b14e21080ff.ReportServer.ReportExecutionService.LoadReport(String Report, String HistoryID)
   at ST_489cafcbe82c45eb9f591b14e21080ff.ScriptMain.Main()

Script Task Source Code:

    Public Sub Main()
        Try
            Try
                For Each _File As String In Directory.GetFiles(Path.GetDirectoryName(Dts.Variables("User::FullFilePath").Value.ToString), "*.pdf", SearchOption.AllDirectories)
                    File.Delete(_File)
                Next
            Catch ex As UnauthorizedAccessException
                Dts.Variables("User::ErrorOutput").Value = Dts.Variables("User::ErrorOutput").Value.ToString() + " " + ex.ToString()
                Error (1)
            End Try

            Dim objRSExec As New ReportServer.ReportExecutionService
            Dim objParamDepartment As New ReportServer.ParameterValue

            Dim objParams(1) As ReportServer.ParameterValue

            Dim objResult() As Byte
            Dim objStream As FileStream

            Dim strFileType As String
            Dim strFileExtension As String
            Dim strFullPathName As String

            strFileType = Dts.Variables("User::FileType").Value.ToString
            strFileExtension = Dts.Variables("User::FileExtension").Value.ToString
            strFullPathName = Dts.Variables("User::FullFilePath").Value.ToString

            With objParamDepartment
                .Name = "DepartmentId"
                .Value = Dts.Variables("User::DepartmentID").Value
            End With

            objParams(0) = objParamDepartment

            With objRSExec
                .Credentials = System.Net.CredentialCache.DefaultCredentials
                .Url = Dts.Variables("User::ReportServer").Value.ToString + "reportexecution2005.asmx"
                .LoadReport(Dts.Variables("User::ReportName").Value.ToString, Nothing)
                .SetExecutionParameters(objParams, "en-us")
                objResult = .Render(strFileType, Nothing, strFileExtension, Nothing, Nothing, Nothing, Nothing)
            End With

            objStream = File.Create(strFullPathName, objResult.Length)

            With objStream
                .Write(objResult, 0, objResult.Length)
                .Close()
            End With

            Dts.Variables("User::FileExists").Value = File.Exists(Dts.Variables("User::FullFilePath").Value.ToString)

            Dts.TaskResult = ScriptResults.Success
        Catch ex As Exception
            Dts.Variables("User::ErrorOutput").Value = Dts.Variables("User::ErrorOutput").Value.ToString() + " " + ex.ToString()
            Error (1)
        End Try
    End Sub

How to force packages to read updated value of Environment Variable

$
0
0

hi there, I've created an EV in my local machine and tested my package in my local machine as well.

Now, I need to modify the value of EV but seems my package was still reading the old EV value. 

Is there anyway to refresh package so that it will read the new value of EV?

thanks

-H


--Currently using Reporting Service 2000; Visual Studio .NET 2003; Visual Source Safe SSIS 2008 SSAS 2008, SVN --

Dynamically Create Variables in Script Task of SSIS

$
0
0

How to Dynamically Create Variables in Script Task. Urgent Please!!

I am using 

Dts.Variables.Add("myVar1", true, "User", 5); 

method but its giving error like this:

Exception from HRESULT: 0xC0016026 ---> System.Runtime.InteropServices.COMException (0xC0016026): Exception from HRESULT: 0xC0016026
   at Microsoft.SqlServer.Dts.Runtime.Wrapper.IDTSVariables100.Add(String bstrName, Boolean bReadOnly, String bstrNamespace, Object vValue)
   at Microsoft.SqlServer.Dts.Runtime.Variables.Add(String name, Boolean readOnly, String nameSpace, Object val)
   --- End of inner exception stack trace ---
   at Microsoft.SqlServer.Dts.Runtime.Variables.Add(String name, Boolean readOnly, String nameSpace, Object val)
   at ST_3de12d4b97354b57bf8c88a45589084f.csproj.ScriptMain.Main()
   --- End of inner exception stack trace ---


avm

Run SSIS package deployed in Integration Service Catalog (SSISDB) as a SQL Agent Job based on a XML Configuration File

$
0
0

Hi,

I am using SQL Server 2012 (SSIS). In Project Deployment Model is there a way to run the package deployed in SSIS Catalog as a SQL Agent Job based on XML Configuration file.

Thanks,

Rehan

I want to run the package deployed in Integration Service Catalog (SSISDB) in job based on a XML Configuration File

$
0
0

Hi,

I am using SQL Server 2012 (SSIS). In Project Deployment Model is there a way to run the package deployed inSSIS Catalog as a SQL Agent Job based on XML Configuration file.

Thanks,

Rehan

SSIS develop package difficult

$
0
0
SSIS develop package difficult...

SSIS & CRM

$
0
0

SQL2012

I have installed the Kingsway component for CRM2011

I have a custom entity called fm_Arudd.  What I am trying to do is get the nest serial number from the fm_serial field. Can anyone give me any pointers?


Dont ask me .. i dont know


Child package executes without error but calling package raises error

$
0
0

I have a fairly complex SSIS package, organized into stages.   A primary package calls 4 secondary packages, each of which then in turns calls a large number of tertiary packages.  The package has worked in a developer environment, but when deployed for user testing the package is failing in an odd way.

From the console logging, you can see the primary package validate, then execute the first secondary package.  The secondary package validates, then executes the first tertiary package - the first package with an actual data flow.   The tertiary package validates, and then executes to completion (all data is put in place correctly) and without error.  But, the secondary package then reports that the execution of the tertiary package failed, and since this is an error and it is not supposed to ignore any errors, it aborts as failed as well.

There is absolutely nothing in the logs that suggests an error.  What could be causing the parent package to believe that the child package had an error, when the child package correctly executed and did not log an error?

Any advice at all would be greatly appreciated?


error job After got SSIS VB Script be able to refresh existing excel file without human intervention

$
0
0

Hi everyone,

After got  SSIS VB Script be  able to refresh existing excel file  without human intervention,

and changed the security level to No encryption.

My sql server services are:

Common Name

State

Log on

SQL Server

Running

Domain\My_user

SQL Server Agent

Running

Domain\My_user

SQL Server Analysis Services

Running

Domain\My_user

SQL Server Browser

Stop

NT_autorithy\local_Server

SQL Server Full Text Search

Running

NT_autorithy\local_Server

SQL Server Integration Services

Running

Domain\My_user

SQL Server Reporting Services

Running

NT_autorithy\networkservices

 

 I Still NOT be able to get work in JOB.

What could be the issue?

message:

-------------------Start error message

Executed as user: domain\my_user. Microsoft (R) SQL Server Execute Package Utility  Version 10.50.4000.0 for 64-bit  Copyright (C) Microsoft Corporation 2010. All rights reserved.    Started:  5:45:54 PM  Error: 2013-01-25 17:45:56.11     Code: 0x00000001     Source: Script Task      Description: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x800A03EC): Microsoft Excel cannot access the file '\\computer_name\test\test.xlsm'. There are several possible reasons:   

? The file name or path does not exist. 

? The file is being used by another program

? The workbook you are trying to save has the same name as a currently open workbook.    

at Microsoft.Office.Interop.Excel.Workbooks.Open(String Filename, Object UpdateLinks, Object ReadOnly, Object Format, Object Password, Object WriteResPassword, Object IgnoreReadOnlyRecommended, Object Origin, Object Delimiter, Object Editable, Object Notify, Object Converter, Object AddToMru, Object Local, Object CorruptLoad)    

at ST_6ff4b1e36fef45a5b3d3f0c9e3b0c825.vbproj.ScriptMain.Main()     --- End of inner exception stack trace ---    

at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)    

at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)    

at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)    

at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)    

at Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTATaskScriptingEngine.ExecuteScript()  End Error  DTExec: The package execution returned DTSER_FAILURE (1). 

Started:  5:45:54 PM  Finished: 5:45:56 PM  Elapsed:  1.498 seconds.  The package execution failed.  The step failed.

-------------------End error message

fails inSQL Agent Job (works when executed from BIDS)!!!

 I tested on the server itself, or on my machine for development and I get the same thing

Thanks in advance!!




cris


script component as datasource with stored prcedure

$
0
0

I am trying to use the script component as a datatask source

The stored procedure takes a varchar(250) parameter

I have created the output columns and got so far in the script but am now stuck

can anyone guide me

Public Class ScriptMain
    Inherits UserComponent
    Dim connMgr As IDTSConnectionManager100
    Dim sqlConn As SqlConnection
    Dim sqlCmd As SqlCommand
    Dim sqlParam As SqlParameter
    'This method is called once, before rows begin to be processed in the data flow.
    '
    'You can remove this method if you don't need to do anything here.
    Public Overrides Sub AcquireConnections(ByVal Transaction As Object)
        connMgr = Me.Connections.MYConnection
        sqlConn = CType(connMgr.AcquireConnection(Nothing), SqlConnection)
    End Sub
    Public Overrides Sub PreExecute()
        MyBase.PreExecute()
        sqlCmd = New SqlCommand("EXECUTE sp_CRM_ImportARUDD", sqlConn)
        sqlCmd.CommandType = CommandType.StoredProcedure
        sqlParam = New SqlParameter("@FileName", SqlDbType.NVarChar, 250)
        sqlParam.Direction = ParameterDirection.Input
        sqlCmd.Parameters.Add(sqlParam)
    End Sub
    Public Overrides Sub PostExecute()
        MyBase.PostExecute()
        '
        ' Add your code here
        '
    End Sub
    Public Overrides Sub CreateNewOutputRows()
        '
        ' Add rows by calling the AddRow method on the member variable named "<Output Name>Buffer".
        ' For example, call MyOutputBuffer.AddRow() if your output was named "MyOutput".
        '
    End Sub
End Class


Dont ask me .. i dont know

config file, mismatching connection object name

$
0
0

Here is the situation and I would like to know what the expected behavior is.

I have an agent job running a package with a config file. The config file has bunch of properties set for a connection object. Let's say the connection object name is "AdventureWorks_DBConn". In the config file, there is information that says the connection object "AdventureWorks_DBConn" gets ServerName = something, Login = something, Password = something. I am posting this away from my office so I can't see the exact format of the config file, but hopefully, the experts reading this will know what I'm describing.

What happens when I edit the config file so that the connection object reference isn't "AdventureWorks_DBConn" anymore? What if I edit it to something that doesn't exist. Would you expect the agent job to:

(1) give you an error saying that you have a reference to a connection object in the config file that doesn't exist in the package? Or

(2) ignore that reference and use the values that got deployed with the package?

The behavior I am seeing is (2). But I thought I saw somewhere during my testing, that I was getting (1), but I am not able to replicate (1) and I could have been confusing myself. So I wanted to ask if someone can tell me what the expected behavior is.


How to read gmail attachment in SSIS as a Data Flow Source?

$
0
0
Hi,

I have got a package in SSIS which does all the cleaning and loads the data into Sql server table. But at the moment the input source (csv file) is provided manually and saved at a location for the package to pick the file from that location. I get this csv file into our gmail account as an attachment.

I am looking for a way if SSIS can read the email and fetches the attachment so that this manual step can be removed.

Do I need to have some kind of plugin installed or can it be done using inbuilt options in SSIS?

Any help would be much appreciated.

Thanks

H
Viewing all 24688 articles
Browse latest View live


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