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

Create table and import Flat file data based on flat file

$
0
0

Hi ,

I have a requirement where i have import flat files to SQL Server 2012 DB Table dynamically. I have already used Script task to read the first row of the flat file and generated the create table script. I was able to execute the create table from the Execute SQL task using variable. But i'm not able to map the flat file source columns to the OLE-DB destination (recently generated table). Column names have special charaters. Please suggest me to overcome this issue.



Thanks, Thiya



SSIS variable naming conventions?

$
0
0
Anyone got a link for SSIS variable naming conventions?

SSIS Expression for Send Mail Task

$
0
0

HI Guys ,

 I am working on SSIS task - Send Mail task . I am looking for expression  for 

Subject Line - automatically pick up machine name and package name e.g SSIS package "Package name" Failed on "Machine Name"

Message Source - send a detail error message where SSIS package failed in e-mail.

Thank You


Please Mark As Answer if it is helpful. \\Aim To Inspire Rather to Teach

SQL 2012 SSIS Single Package Deployment

$
0
0

I have the following scenario:

I have a 2012 SSIS project that contains two packages and on the release of the project, I deploy the entire project solution which has both packages. I then create a SQL Agent job that executes the packages from the SSIS catalog and all is well.

Down the road, a change is required for both packages and both packages are being developed. The first package change is ready to be deployed and the business wants the change to be implemented and does not want to wait for the second package development.

How do I deploy my project to get the first package deployed without overwriting the second package? I do not want to drop out the second package from the project because the agent job is depending on the package to be located in the catalog. However, I cannot just create a new project deployment with the second package changes since the second package is not ready to be deployed yet.

Is this possible? In the deployment wizard, nothing is available to select only a specific package to update.

I want to take advantage of the SSIS catalog for configuring connections, parameters and the like but this ability to replace a single package needs to be available.

Can we do something in Powershell to add the updated package to the packages collection, which will overwrite the existing package or would that mess up the project deployment and the OOTB versioning that exists?

Or, is the workaround to create a new project with the Package One Updates and the original Package Two, walk through the deployment wizard to create the ISPAC file and then deploy that project to the catalog. (I guess answering my own question here but really hoping for something more elegant)

Thanks in advance

Chuck 

Purpose SSIS Naming Conventions

$
0
0

Hi,

What is the purpose(/advantage) of the SSIS naming conventions (prefix for tasks and transformations by Jamie Thomson)? How can I convice my teammembers to use them?

And are there any other naming conventions? For SSIS variables, connection managers, packagenames, projects, etc.? Please share your naming conventions...

Thanks in advance

Trying to understand how to make a change to a SSIS package

$
0
0

I was pretty familiar with DTS packages but SSIS packages have me completely lost.

Let me start by saying we use TFS (Team Foundation Server) and Visual Studio 2010 for source control and development.

I have to make a change which is very simple. I have to add a new field to an export file.

My problem is I dont know what SSIS is or what all the components mean and what they are used for. I have no clue where to make this change. Does SSIS have any concept of 'source code'. How would an export file layout be defined and where would I look for it? I have read something about a 'manifest file' but again I don't know what it is or what it is used for or where I could find it.

I have to make this change in TFS via Visual Studio but I don't see anything in the solution that looks like the SSIS stuff I need. If it is not there, I need to find it (on the production server maybe?) and add it to TFS.

Is there a good online tutorial that explains all this? I tried the Microsoft ones and they are impossible to follow since they consist of dozens of links that completely tie you in knots.

Derived Column Transformation Editor and a Date

$
0
0

My vendor file used to have "N/A" in the Date field and I used a Derived Column Transformation Editor to feel this out with the following expression...

PAPER_STOP_DATE == "N/A" ? NULL(DT_WSTR,50) : PAPER_STOP_DATE

Now the vendor has also decided to pass nothing in there. So I honestly don't know if it's a "" or a <NULL>. It's coming from an Excel spreadsheet.

Is there any easy way to add "" to this expression and how? Or is there a way to determine if this field is a proper date format?

This is the date that exists in the cell...

03-aug-2014

After I determine if it is a "N/A", I am doing a Data Conversion on it and it is properly loading to our SQL Server Database.

Thanks in advance for your review and am hopeful for a reply.

ITBobbyP85

unable to retrive folder name using filepath

$
0
0

Hi,

My folder structure is like

d\Root\Dir1\file1.txt

d\Root\Dir2\file2.txt

d\Root\Dir3\file1.txt

I want to retrieve the folder of that particular file i.e,     Dir1,Dir2,Dir3.

By using file path I am unable to retrieve it only one folder name can fetch...not all folders names....please suggest me to go further..

I used variable as file path : d\Root\Dir1\file1.txt

I gave one more var as Folder name : Exp:     (SUBSTRING(@[User::FilePath],
LEN(@[User::FilePath]) - FINDSTRING(REVERSE(@[User::FilePath]),"\\",1) + 2,
(LEN(@[User::FilePath]) - FINDSTRING(REVERSE(@[User::FilePath]),"\\",1)) - (LEN(@[User::FilePath]) - FINDSTRING(REVERSE(@[User::FilePath]),"\\",2)) - 1)

By using this expression I can retrieve only one folder name calledDir1 but loop 'll repeat for all folders issue is unable to retrieve that folder name for all iterations. it 'll showing same folder for all records.

Please find it and let suggest a right way further.

Thanks

AVS


Data flow tasks faills while loading from database to excel

$
0
0

Hello,

I am getting error while loading from oledb source to excel and the error as shown below.

Error: 0xC0202009 at DFT - Company EX, OLE DB Destination [198]: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005.

Error: 0xC0209029 at DFT - Company EX, OLE DB Destination [198]: SSIS Error Code DTS_E_INDUCEDTRANSFORMFAILUREONERROR.  The "input "OLE DB Destination Input" (211)" failed because error code 0xC020907B occurred, and the error row disposition on "input "OLE DB Destination Input" (211)" specifies failure on error. An error occurred on the specified object of the specified component.  There may be error messages posted before this with more information about the failure.

Error: 0xC0047022 at DFT - Company EX: SSIS Error Code DTS_E_PROCESSINPUTFAILED.  The ProcessInput method on component "OLE DB Destination" (198) failed with error code 0xC0209029. 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.

Error: 0xC02020C4 at DFT - Company EX, OLE DB Source 1 [1]: The attempt to add a row to the Data Flow task buffer failed with error code 0xC0047020.

Error: 0xC0047021 at DFT - Company EX: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread0" has exited with error code 0xC0209029.  There may be error messages posted before this with more information on why the thread has exited.

Error: 0xC0047038 at DFT - Company EX: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED.  The PrimeOutput method on component "OLE DB Source 1" (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.

Error: 0xC0047021 at DFT - Company EX: SSIS Error Code DTS_E_THREADFAILED.  Thread "SourceThread0" has exited with error code 0xC0047038.  There may be error messages posted before this with more information on why the thread has exited.

Any help would be appreciated ASAP.

Thanks,

Vinay s


I have a scenario like this please give me any suggestion hw to i approach?

$
0
0

I am having ErrorCode ,ErrorMessage,ETLCreatedBySourceID columns in my table..

At the time of new  data inserting the system will generate sourceId  will generate automatically and also 
ErrorCode column data type is bit, so based on the Errorcode I have to generate ErrorMessage..
I didn't get how to do this..
So can u please help me..
My output like attached document...

please give me a solution for this

Pls suggest for this...

ErrorErrorMessage
1Fact not mapping to following dimensions: Circle
1Fact not mapping to following dimensions: Channel
1Fact not mapping to following dimensions: Handset
1Fact not mapping to following dimensions: Channel
1Fact not mapping to following dimensions: Circle
1Fact not mapping to following dimensions: Channel
1Fact not mapping to following dimensions: Handset
1Fact not mapping to following dimensions: Circle
1Fact not mapping to following dimensions: Handset

Thanks!



DtsDebugHost crashes after upgrade to SQL 2012 SP2

$
0
0

We have an SSIS package developed in VS 2010 (10.0.40219.1 SP1) running against SQL Server 2012.

Since we've upgraded to SQL Server 2012 SP2 (11.0.5058) one of the previously working packages is failing.

When running in SQL Agent, we get the following error:

The step did not generate any output.  The package execution failed.  The step failed.

When running in BIDS (VS 2010), we get the following crash:

---------------------------
Microsoft Visual C++ Runtime Library
---------------------------
Runtime Error!
Program: C:\Progr...
R6025
- pure virtual function call

In the Event Log, the following appears:

Faulting application name: DtsDebugHost.exe, version: 2011.110.5058.0, time stamp: 0x537422a5
Faulting module name: MSVCR100.dll, version: 10.0.40219.325, time stamp: 0x4df2bcac
Exception code: 0x40000015
Fault offset: 0x00000000000761c9
Faulting process id: 0x10da0
Faulting application start time: 0x01cfcbb6ddbc218e
Faulting application path: C:\Program Files\Microsoft SQL Server\110\DTS\binn\DtsDebugHost.exe
Faulting module path: C:\Windows\system32\MSVCR100.dll
Report Id: 28659fee-37aa-11e4-8361-50e549e06c22

Is there a desired application in which to build SSIS Expressions or does most everyone use Notepad like I do?

$
0
0

Just wondering if there's a freebie application out there or what people actually use to build SSIS Expressions. I use Notepad and then copy and paste but that seems a bit archaic.

Thanks for your review and am hopeful for a reply.

ITBobbyP85

SSISDB

$
0
0
Now that I have configure my SSIS cataloge which in turn create a SQL DB SSISDB. My DBA come back and tells me its configured wrong and need to be corrected as part of company standard. I wanted to make sure these changes doesn't mess up with its performance as SQL did for us and I am assuming that is an optimal config . Are their any best practices or recommendation to change after SSISDB is build. Like we wanted to recovery model to simple instead of FULL and manage the growth of log.

Moyz Khan

Edit/deploy SSIS package for SQL Server 2012 in Visual Studio 2013

$
0
0

Hi.

Yesterday, I installed SQL Server Data Tools (SSDT) for VS 2013. My goal was to get rid of VS 2012 on my machine, and simply edit all my code (including SSIS projects) in VS 2013.

However, since my production server is running SQL 2012, I run into problems when I deploy the SSIS package from VS 2013. It seems that the Version property of the package is "bumped" from 6 to 8 whenever the project is opened in VS 2013. As a result, I get the following error when the package runs on my SS 2012 server:

"The version number is not valid. The version number in the package cannot be higher than current version number."

So, my question in short is this: 

Is there a way to build/edit SSIS projects in the latest VS 2013/SSDT, but for execution on SS 2012?

Regards,

Thomas





VS 2013 Opening SSIS Solution with multiple projects that have protection level set

$
0
0

We are in the process of converting all of our old SQL 2008 SSIS packages to VS 2013/SQL 2014. I've done the conversion process in VS 2013 and also started the conversion of Package Deployment to Project Deployment. We currently use Encrypt All With Password as a protection level in the packages. However, I now notice that one the ones I've converted to Project Deployment that when I open the solution each of those projects asks me for the password even though i haven't started any work in those projects. This is different than the remaining packages I have not converted where it is not asking me for the password yet. With well over 30 projects in the solution, I can't see having to type in 30 passwords for all the projects when I know I'm only going to be working on one.

The current setup is one solution with multiple projects and each project is one package.  This allows us to only deploy that package that we need to update and not all packages if the setup was one solution/one project/multiple packages.

Is there a setting that I am missing? Or a workaround?

Thanks.


Pull data from SQL Table and display it in mail

$
0
0

I have a requirement to pull the data from SQL table and send it in email.  Currently I am sending the hard coded info in email but is it possible to pull some data from SQL Table and than format it and send it across in the same email? 

Can you guide me with steps on this.


Neil

Multiple rows into single row in DFT

$
0
0

Hi,

In the DFT task after performing certain operations, I have data similar to the below structure.

Name       Value  --       ---------  AnimalLionAnimalTiger  AnimalHorse  BirdParrot  BirdEagle

My requirement is to transform the above data as below for the destination table.

Name    Value--    ----------    AnimalLion, Tiger, HorseBirdParrot, Eagle 

Is this possible using the Script task transformation? 

thanks in advance.

- Leah


Unable to use Custom SSIS Source Component

$
0
0

Hello,
I am in a very desperate situation as I am unable to make progress on my project due to this issues.  I am developing a custom SSIS Source Component and I am unable to use it even after successful compilation.  I am trying this bare bone component which is also not working.

Development Environment
Windows 2008 R2 (64bit)
SQL Server 2008
Visual Studio 2012

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

Microsoft.SqlServer.Dts.Design.dll
Microsoft.SqlServer.DTSPipelineWrap.dll
Microsoft.SQLServer.DTSRuntimeWrap.dll
Microsoft.SQLServer.ManagedDTS.dll
Microsoft.SqlServer.PipelineHost.dll

Steps followed

Step #1 - Created a Visual C# Class Library
[DtsPipelineComponent(DisplayName="XCustomComponent", ComponentType=ComponentType.SourceAdapter)]
public class XCustomComponent : PiplelineComponent
{
 ....
 //Override methods
}

Step #2 - Signed the Assembly
Created a .snk file using sn and signed the assembly in Visual Studio 2012 by selecting the .snk file (also tried .pfx file).

Step #3- Copied the dll to below folders
Copied the .dll file to both the folders below to be safer
C:\Program Files (x86)\Microsoft SQL Server\100\DTS\PiplelineComponents
C:\Program Files\Microsoft SQL Server\100\DTS\PiplelineComponents

Step #4- Registered the dll in GAC
Ran Developer Command prompt for Visual Studio 2012 with Admin privileges and executed the command gacutil -iF c:\MyCustomComponents\MyCustomComponents.dll

Problem
Firstly I am unable to see the component in the Toolbox.

When I open SQL Server Data Tools Visual Studio 2012 and Tools->Choose Toolbox Items.. and select the dll from by debug folder I am getting the following error:
There are no components in 'c:\MyCustomComponents\MyCustomComponents.dll' that can be placed on the toolbox.

When I open SQL Server Business Intelligence Development Studio and Tools->Choose Toolbox Items.. and select the dll from by debug folder I am getting the following error:
'c:\MyCustomComponents\MyCustomComponents.dll' is not a Microsoft.NET module.

I googled and tried different options but nothing seems to work, already wasted 1wk.

Target framework is .NET Framework 4 (tried 4.5 and as well 3.5)
Platform is Any CPU (tried x86 and as well x64)

My guess is may be I am not using the right combination of Framework Version/Gacutil version/Target Platform.  I am not sure, please help as its really frustrating and losing time on my project.

Thank you


Best way to look through MySQL databases using SSIS 2012

$
0
0

Hi

I am struggling to find a better way to loop through MySQL databases.

I have two MySQL server with more than 20 databases on each server. These two server has the same table structure but the name of database is different (based on region). As they have the same data structure I am trying to find a way to loop through the databases to perform the same query in the data flow task.

Basically, I want to paramatise the connection string of MySQL something like changing initial catalog in SQL.

I'd like to store database information in a table with key values and retried them to dynamically create a connection file.

I know I can do this in SQL but I can not figure it out for MySQL. Because I am using ADO.Net source for MySQL, I cannot even use SQL command from variables (I thought I could loop through and create a sql query which includes a database name).

I'd like to know if there is a way to do this. It's really hassle to work with databases other than SQL in SSIS.

List of values in Variable passed into Execute SQL Statement

$
0
0

This seems like it would be a reasonably easy task in SSIS but I cannot seem to get it to work. 

A simple example:

Execute SQL Task I wan to use the SQL below:

Select x,y,z

from TableA

where x in (a,b,c)

I want to populate a variable MyList elsewhere in SSIS with a,b, and c  such that the Execute SQL task becomes

Select x,y,z

from TableA

where x in (MyList)

Is such a beast possible in SSIS either in Execute SQL Task or elsewhere?  Seems like a not horribly demanding request but I don't see any examples yet. 

Thanks kindly,

Mike

Viewing all 24688 articles
Browse latest View live