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

SSIS copy specifc file list

$
0
0

Hello,

I create a package with script task who retrieve list of file using  (   downloadedFiles = new DirectoryInfo(download_path).EnumerateFiles(data + "*.bak", SearchOption.TopDirectoryOnly).ToList().OrderBy(o => o.LastWriteTime);

availablebase.Add(downloadedFiles.ElementAt(0));

 

I can retrieve the newest file =>OK 

and I want to use file system task to perform a copy for each file in availablebase. 



SSIS Packages keep throwing offlinemode is TRUE when it is not, validation fails

$
0
0

I upgraded an SSIS solution from SQL 2008R2 spec to latest SQL 2014. Everything was good at my home pc yesterday.

Today when i opened the solution in my work laptop, i got errors regarding the encryption.

So i changed the package properties settings from EncryptSensitiveWithUserKeyto EncryptSensitiveWithPassword and set a password.

After that the packages do not complain about security byut they keep complaining aboutoffline mode is true when there is nowhere true value.

Screenshots from Notepad++ search in all files and Visual Studio errors.


Elias

Issue During Zipping Files

$
0
0

Hello Everyone,

I have created a package which zips all the files in a folder and move it to Archive. Everything works fine, but problem is

I have 12 Files in the folder, file size varies from 1mb to 300 mb, in the execute Process Task, I am using particular Arguments.

@ArvhicePath = C:\Users\Desktop\WORK\Tasks\Archive

"a -t7z  "+ @[User::ArchivePath] + "FilesZipped" +"_"+

 (DT_STR, 4, 1252) MONTH( DATEADD( "mm", 0, Getdate() ))  +

 (DT_STR, 4, 1252) DAY ( DATEADD( "dd",0, Getdate() ))  +
(DT_STR, 4, 1252) YEAR( DATEADD( "YYYY", 0, Getdate() )) +"_" +
 Right("0" + (DT_STR,4,1252) DatePart("hh",getdate()),2)  +
Right("0" + (DT_STR,4,1252) DatePart("mi",getdate()),2)  +
Right("0" + (DT_STR,4,1252) DatePart("ss",getdate()),2) +".zip"+" "+ 

 @[User::Filaname]

Now I expected it would zip all the Files Into Single Zip file, but all the 11 files are distributed into 6 sometimes and 7 or 8 sometimes, with same name.

Is there a Way I could Zip all the files in a Folder into one single Zip File?

Thanks


Thanks, Please Help People When they need..!!! Mark as answered if your problem is solved.

Do package data sources update all connected connection managers automatically?

$
0
0

I converted a big project from SSIS2008 -> SSIS2014

During conversion i also erased all connection managers and recreated them based on the packages data sources.

Now i want to test my packages on another server , so i changed my 2 data sources only.

When i open the packages can see on the connectionstring the old server. 

If i dont do anything else and press start, what will happen?

Will the package update itself automatically and get the connection string of the data source or not?


Elias

SSIS 2012 Deployment of Single Package

$
0
0

Hello,

I have an SSIS project that has been deployed to the SQL Server 2012 Integration Services catalog using the project deployment model. Is it possible to redeploy a single package to the project on the ssis server without having to redeploy all packages in the project? We are trying to get around not having to regression test previously deployed packages if there was no change to the previously deployed packages.

If not, are there any work-arounds that anyone has come up with?  Our environment is very controlled and they look down on redeploying objects where there are no changes.

Thanks for any input.
Letron

The runtime connection manager with the ID "GUID" cannot be found. Verify that the connection manager

$
0
0

Hi All,

Currently I'm trying to execute SSIS package which pulls data from SQL Server 2008 Adventure Works DB in to SQL Server 2012 Database. 

When ever I execute the package through SQL Server Data Tools for Visual Studio 2012, Package execute without errors and pulls 18,000+ records from SQL 2008 


I created a proxy and used as described in "http://msdn.microsoft.com/en-us/library/dd440761.aspx"

if I try to execute package manually or as SQL Server Job (SQL Server Agent) I get following Error 

Executed as user: "AD\ProxyUser". Microsoft (R) SQL Server Execute Package Utility  Version 11.0.2100.60 for 64-bit  Copyright (C) Microsoft Corporation. All rights reserved.    Started:  11:15:43 PM  Error: 2014-10-08 23:15:43.92     Code: 0xC020801B     Source: Export IndividualCustomer OLE DB Destination [2]     Description: The runtime connection manager with the ID "{3AFDAFE8-0325-403E-8152-5DD95C56AE83}" cannot be found. Verify that the connection manager collection has a connection manager with that ID.  End Error  Error: 2014-10-08 23:15:43.92     Code: 0xC0047017     Source: Export IndividualCustomer SSIS.Pipeline     Description: OLE DB Destination failed validation and returned error code 0xC020801B.  End Error  Error: 2014-10-08 23:15:43.92     Code: 0xC004700C     Source: Export IndividualCustomer SSIS.Pipeline     Description: One or more component failed validation.  End Error  Error: 2014-10-08 23:15:43.92     Code: 0xC0024107     Source: Export IndividualCustomer      Description: There were errors during task validation.  End Error  DTExec: The package execution returned DTSER_FAILURE (1).  Started:  11:15:43 PM  Finished: 11:15:43 PM  Elapsed:  0.219 seconds.  The package execution failed.  The step failed.

Please note : GUID :3AFDAFE8-0325-403E-8152-5DD95C56AE83 is belongs to Destination Data Connection 

XML for Destination Data connection as follows

<?xml version="1.0"?>
<DTS:ConnectionManager xmlns:DTS="www.microsoft.com/SqlServer/Dts"
  DTS:ObjectName="[ServerName].[DBName]"
  DTS:DTSID="{3AFDAFE8-0325-403E-8152-5DD95C56AE83}"
  DTS:CreationName="OLEDB">
  <DTS:ObjectData>
    <DTS:ConnectionManager
      DTS:ConnectionString="Data Source=[ServerName];Initial Catalog=[DBName];Provider=SQLNCLI11.1;Integrated Security=SSPI;Auto Translate=False;" />
  </DTS:ObjectData>
</DTS:ConnectionManager>

Appreciate if any one can give an Idea

Thanks in Advance

Tharindu 

CSV File import into Sql Server table via SSIS

$
0
0

Hello -

I will be importing csv files on a nightly basis (one per night, I think) into a SQL Server table using SSIS.  

When I am done with the csv file, I need to move it to a "completed" folder.  Maybe it's just the end of the day, but I am not readily coming up with a way to do this.  

Any suggestions will be appreciated!

Juniormint

How to Format a excel template sheet column data using ssis

$
0
0
Hi,
I am filling an excel sheet named sheet1 of a predefined template using SSIS. The template has many other sheets which are calculated using predefined formulas referring sheet 1. Currently I am able to successfully fill the data in sheet1 but other sheets not getting populated until I manually perform Text Column conversion on few columns like Date,Time(hh:mm:ss). Could some one please help me to achieve this task. Can I automate the Text to Column conversion operation after filling the excel.

Thanks in advance,
Jithu

calling a restful web service from a script task

$
0
0

Hi.  I'm weak in c# but am looking to accomplish this...

I want to call a RESTful web service from an ssis script task.  I don't want to create a web service so I'm hoping there is some publicly available one I can practice with before our web team provides me with the service I'll eventually use.  Can the community provide an example?  I wish I had more but my knowledge is very limited except for using ssis in more sql centric apps.  It would be great if I could exercise both a get and put verb but I understand i'll be lucky if I can even get a get to work. 

Here is an example of a get I found on the web but I don't know if its a viable candidate for me to practice with from my package...

using System;

using System.IO;

using System.Net;

using System.Text;

// Create the web request

HttpWebRequest request = WebRequest.Create("http://developer.yahoo.com/") as HttpWebRequest;

// Get response

using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)

{

    // Get the response stream

    StreamReader reader = new StreamReader(response.GetResponseStream());

    // Console application output

    Console.WriteLine(reader.ReadToEnd());

}

and in the same article an example of a put ...

// We use the HttpUtility class from the System.Web namespace
using System.Web;
Uri address = new Uri("http://api.search.yahoo.com/ContentAnalysisService/V1/termExtraction");
// Create the web request
HttpWebRequest request = WebRequest.Create(address) as HttpWebRequest;
// Set type to POST
request.Method = "POST";
request.ContentType = "application/x-www-form-urlencoded";
// Create the data we want to send
string appId = "YahooDemo";
string context = "Italian sculptors and painters of the renaissance"+ "favored the Virgin Mary for inspiration";
string query = "madonna";
StringBuilder data = new StringBuilder();
data.Append("appid=" + HttpUtility.UrlEncode(appId));
data.Append("&context=" + HttpUtility.UrlEncode(context));
data.Append("&query=" + HttpUtility.UrlEncode(query));
// Create a byte array of the data we want to send
byte[] byteData = UTF8Encoding.UTF8.GetBytes(data.ToString());
// Set the content length in the request headers
request.ContentLength = byteData.Length;
// Write data
using (Stream postStream = request.GetRequestStream())
{
        postStream.Write(byteData, 0, byteData.Length);
}
// Get response
using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)
{
        // Get the response stream
        StreamReader reader = new StreamReader(response.GetResponseStream());
        // Console application output
        Console.WriteLine(reader.ReadToEnd());
}

 

LogProviders.Add fails with "not recognized as a valid log provider type." in Data Tools but not BIDS

$
0
0

In attempting to add standard DTS logging to a package via Data Tools, I found that my attempt to execute:

        Dim provider As LogProvider = p.LogProviders.Add("DTS.LogProviderTextFile.2") 

(or any other log provider type,) resulted in:

The log provider type "DTS.LogProviderTextFile.2, {0A039101-ACC1-4E06-943F-279948323883}" specified for log provider "{CC5CB9A4-E0D5-4ECD-8F4E-1E8FB9BDE8A6}" is not recognized as a valid log provider type. This error occurs when an attempt is made to create a log provider for unknown log provider type. Verify the spelling in the log provider type name.

I created a new package with a single script task using only the example code from the MS documentation for Embedding Logging Programmatically at:

http://msdn.microsoft.com/en-us/library/ms136023(v=sql.110).aspx

consisting of:

Imports Microsoft.SqlServer.Dts.Runtime

Module Module1

  Sub Main()

    Dim p As Package = New Package()

    Dim loggingConnection As ConnectionManager = p.Connections.Add("FILE")
    loggingConnection.ConnectionString = "C:\SSISPackageLog.txt"

    Dim provider As LogProvider = p.LogProviders.Add("DTS.LogProviderTextFile.2")
    provider.ConfigString = loggingConnection.Name
    p.LoggingOptions.SelectedLogProviders.Add(provider)
    p.LoggingOptions.EventFilterKind = DTSEventFilterKind.Inclusion
    p.LoggingOptions.EventFilter = New String() {"OnPreExecute", _"OnPostExecute", "OnError", "OnWarning", "OnInformation"}
    p.LoggingMode = DTSLoggingMode.Enabled

    ' Add tasks and other objects to the package.

  End Sub

End Module

I get the same error as listed above in SQL Server 2012 Data Tools on three separate machines.  On my primary dev box, where the code fails in Data Tools, running the exact same code in BIDS runs without problems.

Importing the working BIDS package into Data Tools also fails with the same error.

I have not encountered any other 2012 Data Tools issues, but logging is a core pattern that makes me worry that this is a problem that may emerge with other functions in the DTS toolset.

Thanks for any help!!

generic data import error

$
0
0
I am receiving a very general error in both the Debugger and the EXE (32-bit) when importing an Excel workbook.

-600K rows, issue started coming up after adding a single bit column to it.
-importing from Excel in 32-Bit mode
-SQL 2008
-using DTexec.exe without switches
-have also used the debugger
-the event log does not show anything except that there has been an SSIS error.

The memory usage in task manager is ~15GB there is 16GB on the machine, but, I would expect an out of memory error, wouldn't I?

SSIS data setting for container:
-defaultBufferSize = 542880
-defaultBufferMaxRows = 5000

The error message is very generic and I know there is a specific error for memory so I am having trouble determining what resource has been exceeded.

[Connection manager "GetMyExcel"] Error: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005.

An OLE DB record is available.  Source: "Microsoft JET Database Engine"  Hresult: 0x80004005  Description: "System resource exceeded.".


How do I track this thing down?

thanks.

Missing assembly ManagedDTS 100

$
0
0

I have installed BIDS for sql 2008 and I trying to create a script, it task can not find a reference to ManagedDTS

I went to the folders:

C:\Program Files (x86)\Microsoft SQL Server\100\SDK\Assemblies

and

C:\Program Files\Microsoft SQL Server\100\SDK\Assemblies

and did not find the corresponding dll.

This is a new computer that I have just reinstalled most of the software I had, and I am wondering if I am missed installing something in it. I know for sure that I installed BIDS for sql 2008

What am I missing to install?


Paulino


SSIS Data Validation Errors

$
0
0

I have a weird dilemma. I have a package that imports a xlsx file (only available option) to an access database. The source file has 400,000 rows and I run some VBA to clean it up prior to SSIS touching it.

If I run the vba code and check the data flow excel source preview, it shows all columns populated.

If I open and delete a few records from the source file, it gives me a data validation error, tries to auto fix it when I open the data flow task and then some of the items in certain rows are "null" even though they exist on the spreadsheet.

Has anyone ever experienced this? I am pretty new to SSIS, but so far have been able to figure out most stuff.


Thank you in advance,

Corey

SSIS : Deployment failed on Changing Protection Level stage with XML Error

$
0
0

Hello,

I am using SQL Server Data Tools 2012 version and Project Deployment Model.

I am getting below error while changing Protection level stage of the Deployment on Client's Testing Environment.

The package failed to load due to error 0xC0011008 "Error loading from XML. No further detailed error information can be specified for this problem because no Events object was passed where detailed error information can be stored.". This occurs when CPackage::LoadFromXML fails.

I have created Project parameters to provide Sharepoint Site Connection String and SQL Server Database Connection String.

( Overview of the SSIS Package : Extracting data from SharePointLists and then importing in SQL Tables.)

When I searched for this error, found many ways to set the package configurations forPackage Deployment Model.

What is that thing which I am missing here in the configuration of Package, so that it is not able to encrypt decrypt the mentioned UserID and Password details ?

I have gone through many forums to get clear idea on this, but could not find any solution yet.

Is it something to do with the Integration Services Version and Deployment Utility version same on the Client environment as well ?

Please help.

Thank you,

Mittal.

how to get same metadata configuration for one table out of 70 tables, which is present in diff Servers( TERADATA & SQL Server)

$
0
0

Hi,

I have 70 tables present in Teradata and those same 70 tables present in SQL Server with different names.Now i want to Join them. How can i get table name from Teradata and Related table from SQL Server.

EX: In Teradata Our table Look like V_DMND_XYZ

     Same table present in SQL Server with name: STG_XYZ_ABC

if i want to join both, how can i get same table name from both the servers.

Thanks in advance


Error at Data Flow Task [OLE DB Destination [891]]

$
0
0

I am getting this error message not sure how to resolve this error

Error at Data Flow Task [OLE DB Destination [891]]: The column "Product Desc" cannot be processed because more than one code page (65001 and 1252) are specified for it.

Error at Data Flow Task [OLE DB Destination [891]]: The column "Brand Desc" cannot be processed because more than one code page (65001 and 1252) are specified for it.

Error at Data Flow Task [OLE DB Destination [891]]: The column "Seg Desc" cannot be processed because more than one code page (65001 and 1252) are specified for it.


Smash126

[Solved] How to adjust parameters of an SSIS package in SQL Server when using an SSISDB execution Script (=SP)

$
0
0

Hello,

I created a package in Visual Studio Integration Services, where it runs successfully.

I then deployed it to SQL server 2012. Here to it runs successfully, too.

Then I changed the script in that I exchanged two variables for two parameters - doing the same thing.

I noticed that in VS no dialog window comes up where I could change the value of the parameters; here obviously I am expected to set them in Visual Studio.
However, in SQL Server 2012 the dialog window does come up when I execute the package. I can then change the value of my two parameters and the package runs OK, giving me the expected results.

Now I created a script in SQL Server from which to execute the package. Do I have to change the script every time when I want it to run with different values for the parameters?
So far I have not even found how to feed different values for the parameters into the package by using the script. Or could I tell the script somehow to bring up the dialog window for changing the parameters?

How can I set/change the package parameters by using an SSIS execution script in SQLserver?
Or how could I bring up the dialog window thru the script?

Would s.o have an example?

Help is greatly appreaciated. 
Thank you


Andreas




Do package data sources update all connected connection managers automatically?

$
0
0

I converted a big project from SSIS2008 -> SSIS2014

During conversion i also erased all connection managers and recreated them based on the packages data sources.

Now i want to test my packages on another server , so i changed my 2 data sources only.

When i open the packages can see on the connectionstring the old server. 

If i dont do anything else and press start, what will happen?

Will the package update itself automatically and get the connection string of the data source or not?


Elias

how to get data from a column with datatype sbyte in mysql to a table in sqlserver2012 using ssis

$
0
0

HI All,

We are trying to load data from mysql table to sqlserver 2012.

The source column is of data type SBYTE(mysql).

Destinaltion output column is of data type numeric.

But we are getting the following error while trying to load data using ssis 2012.

Error

The data type of "Test.Outputs[ADO NET Source Output].Columns[col1]" does not match the data type "System.SByte" of the source column "col2".

PLease share your views on this.      Thanks in advance

Missing assembly ManagedDTS 100

$
0
0

I have installed BIDS for sql 2008 and I trying to create a script, it task can not find a reference to ManagedDTS

I went to the folders:

C:\Program Files (x86)\Microsoft SQL Server\100\SDK\Assemblies

and

C:\Program Files\Microsoft SQL Server\100\SDK\Assemblies

and did not find the corresponding dll.

This is a new computer that I have just reinstalled most of the software I had, and I am wondering if I am missed installing something in it. I know for sure that I installed BIDS for sql 2008

What am I missing to install?


Paulino


Viewing all 24688 articles
Browse latest View live


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