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

SQL Server Agent - Job Step Properties [set values tab]

$
0
0

Would like to ask if someone can help me figuring out how to put a shared folder path to the Value column in "Set Value" tab in "Job Step Properties".

I found out that a local path can be set as C:\Folder\subFolder\\  , where you need to put double backslash to the last backslash instead of one, just wondering how would you set a shared folder path like \\Server\folder\subfolder\ .

Any respond will be appreciated :)

Thanks!


Getting DB2 files from Mainframes using SSIS

$
0
0

Hello Friends,

Its been a long time i have'nt been here.... Today i have a good question and i hope all my friends to help me out...

I need to connect to the DB2 server and get a file through ssis.... I tried FTP but it wasnt working. So i tried script task and tried to connect to the db2 server... I was able to connect to the server but unable to get that file in my local path and i need that file in .txt format... 

Please help me in this scenario...

Thanks,

Anji...


Thanks, Anji

Connection failed

$
0
0

Hi All,

Failed to acquire connection database. Connection may not be configured correctly or you may not have the right permissions on this connection. 

sql server agent job fails to run a package

$
0
0

i have a package in my pc which sucess fully runs when i scheduled it in sql server agent job it fails to run.how to check sql server agent credentials

 

Load SSIS .dtsx files (XML) into RDBMS

$
0
0

I feel like I may be reinventing the wheel so I thought I would ask here:

I have 100+ SSIS packages to analyze, get all the connections, procs used, tables touched, queries, all setting etc.  I was instructed to "go throiugh them an take notes" as a method.  Seems pretty 21st century meets the bronze age IMHO.

1) I am confident there are tools out there that can do this -- view 1-1000 packages as a group or one by one and spit out a nice spreadsheet with all the specifics of each or all or any 2 or 1.  i don't have it, doubt I can get it, but just for my entertainment if anyone has a favorite that would be great.  I have found a few, names escpe me, BISPY, something from Sql Sentry, some stuff in codeplex, etc.

2) What i have been attempting is to load the dtsx files into tables in sql server.  It is kind of cumbersome.  But my thought is xml is data, it can be loaded and queried like any data.  Has anyone else done this? Any pointers?   My method is as follows:

a)Upload all the packages to one table myPacks. 

b)Group be all possible settings contained in this specific group of packages (IE Connections, Transformations, Tasks)

c)Since the data is hieratrchical (Connection>Server>Table, EG).create a hierarchy of this list of settings into myTemplate

d)Join myTemplate to myPacks by the keywords to get what pack has what setting and the granular detail.

I have tried working with the MS XSD for ssis and have found it difficult, so I am cheating.

Am I just a crazy dreamer or could this work?

Does SSIS use OpenQuery?

$
0
0

If I run a select statement using the SSIS data transfer widgets does it convert those to an openQuery?

Am I better off just writing my own SQL instead of using the data transfer widgets?

thanks,

CS

Data flow task: Oracle RDB 7.2 and SQL Server 2012

$
0
0

Hello Everyone,

I am a newbie to SSIS just started couple of days ago

Problem Statement: I want to migrate data from SQL Server 2012 to Oracle RDB 7.2 using SSIS Data flow task.

I have tried ADO .NET connection but for multiple records(>1) it fails with error statement ORA00090 : Invalid SQL statement.

I'm not sure even connection I am using will do or not, or there is some setting I am unaware of.

Appreciate your response, Thanks in advance!

--And miles to go before I sleep.

SSIS connectivity to Tally

$
0
0

Hi All,

I have configured the Tally ODBC server to run on the Port 9000. But when I try to connec it thru ssis it gives me the following error.

Am I missing something?

Test connection failed because of an error in initializing provider. ERROR [IM014] [Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application

Thanks, Franco.




xml source editor generate xsd throws an error '♂ '

$
0
0

When I click 'generate' xsd file on xml source editor  ' ', hexadecimal value 0x0B,  is an invalid character. Line 551, position 1418.

How do I deal with this? Is there any issue in xml file? Without changing the xml, how can I handle this from my end?

How do I Initialize SSIS Variables from a Database Table

$
0
0
Hi there,

I would like to extract some configration values (more than one) from database table [Config] to save in variables accordingly.

What is the easiest way to do it?

Is it possible to be done by Execute SQL Task?

Thanks,
Di

Unable to Transfer large no of records (9 Million) from sql server to oracle 11g (64Bit) using SSIS..

$
0
0

Hi ,

I have SQL server 2005 SP4(on win 2k3 R2 32 bit)  from which i am transferring 9 Million recors to Oracle 11g(64 bit) .I have used both oledb provider for Oracle and ODBC driver for oracle to transfer data but all in vain.After transferring some 1 Lacs records its failing.

Please help

Error when using OLEDB provider

Error: 0xC0047011 at Data Flow Task, DTS.Pipeline: The system reports 98 percent memory load. There are 4294070272 bytes of physical memory with 60186624 bytes free. There are 2147352576 bytes of virtual memory with 180776960 bytes free. The paging file has 5727150080 bytes with 1734053888 bytes free.

Information: 0x4004800C at Data Flow Task: The buffer manager detected that the system was low on virtual memory, but was unable to swap out any buffers. 16 buffers were considered and 16 were locked. Either not enough memory is available to the pipeline because not enough is installed, other processes are using it, or too many buffers are locked.

error when using ODBC provider

[OLE DB Destination [16]] Error: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005. An OLE DB record is available.  Source: "OraOLEDB"  Hresult: 0x80004005  Description: "ROW-00060: Internal error: [dainsert,16]ȷ"x ".

[OLE DB Destination [16]] Error: SSIS Error Code DTS_E_INDUCEDTRANSFORMFAILUREONERROR.  The "input "OLE DB Destination Input" (29)" failed because error code 0xC020907B occurred, and the error row disposition on "input "OLE DB Destination Input" (29)" 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.

PS: Using oledb i can transfer only 25 K records using ODBC i can was able to transfer 1Lacs

I also used database export wizard and i was able to transfer just 19lac records

and error which came was

 SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x8007000E.
An OLE DB record is available.  Source: "Microsoft Cursor Engine"  Hresult: 0x8007000E  Description: "Out of memory.".
 (SQL Server Import and Export Wizard)

Error 0xc0047022: Data Flow Task: SSIS Error Code DTS_E_PROCESSINPUTFAILED.


Shashank Singh Soldier..Sir we are surrounded from all sides by enemy.. Major: Good, we can attack in any direction Thats attitude..


Unable to schedule the SSIS by connecting the Excel Source

$
0
0

Hi All,

Thanks in advance.

I have developed the SSIS Package in SQL Server 2008 with 32 bit environment.

My scope of work is to migrate the data from excel source to SQL Server. The package works fine within the BIDS. While executing the same using the SQL Server Agent or using the Command Line , I am getting the error like,

Argument ''Excel'' for option ''Connection'' is not valid.

Following is the connection string, I used for excel connecting the Excel Source.

Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Users\Administrator\Desktop\Sample Upload File.xlsx;Extended Properties="EXCEL 12.0;HDR=YES";

Please find below the error screenshot while executing through the command line,

Thanks

Rajan.S

select Distinct query

$
0
0

HI,

I am using select distinct query in oledb source in ssis.

When I use that query in SQL server I am getting 2000 records from a source which has got 9000 records.

But when I use the same query in ssis oledb source i am getting 4000 records. 

Can someone clarify me on this issue.

Thanks in advance

First character is removed in ntext columns

$
0
0

Hi,

I am trying to copy tables from Filemaker to SQL Server. I am connected to Filemaker with ODBCDriver through ADO.NET Source component.

My destination is OLE DB Destination component connected to SQL Server.  SQL Server receives  data from Filemaker in 3 data types: datetime for dates, float for integers and the rest is in ntext format.

On a preview of the ADO.NET Source I can see that the data that arrives from Filemaker is full and correct but on the output columns in the SQL Destination Table in all the columns with ntext data type the first character is missing.

I tried to convert the data type and I tried to write the data to a flat file. It didn't help and the data still arrives without the first character.

Any ideas?


multi cast issue in SSIS

$
0
0

If I need to load one source data to one flat file and one sql server table. Its basically loading same data to both destinations.

I can do it with multi casting but If I want to disable falt file destination in the future with out changing package, just by changing config file.

How can I do that. Please let me know.


SSIS Today's date

$
0
0

I have an execute sql task and I have to store a global variable GivenDate = getdate().
select @givendate = convert(varchar(10),getdate(),101)    I have selected the parameters and given @givendate  to SSIS variable Date
I get the error "Executing the Query failed".

How do I resolve this? Is there a better method to assign today's date to an SSIS variable?


In the middle of difficulty lies opportunity.

sceduling packages

$
0
0

I created an agent to run two packages in succession, but execution of the 1st package stops when the 1st job completes. Some documentation indicated that I had to set properties in the individual job steps for both success and failure, but I couldn't find any detail as to what properties to set to what. I found Fail Package on Failure and Fail Parent on Failure attributes of the job steps and Fail Parent on Failure under Event Handlers and set them all to True as one posting on the web recommended, but that didn't fix the problem.

Suggestions?

Thanks,

Jnana


Jnana Sivananda

Writing data from stored procedure to flat file in SSIS script task is writing an empty file.

$
0
0

Hello All,

Please help.

I am loading data from sql stored procedure with two results sets into a flat file destination in SSIS script taSK.

My code below is not wrting data to flat fiile. Please help.

using System;
using System.IO;
using System.Data;
using System.Data.SqlClient;
using Microsoft.SqlServer.Dts.Runtime;
using System.Windows.Forms;
#endregion

namespace ST_bc581c6792504a7588c6fc043fde1631
{
    /// <summary>
    /// ScriptMain is the entry point class of the script.  Do not change the name, attributes,
    /// or parent of this class.
    /// </summary>
[Microsoft.SqlServer.Dts.Tasks.ScriptTask.SSISScriptTaskEntryPointAttribute]
public partial class ScriptMain : Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase
{
        #region Help:  Using Integration Services variables and parameters in a script
        /* To use a variable in this script, first ensure that the variable has been added to 
         * either the list contained in the ReadOnlyVariables property or the list contained in 
         * the ReadWriteVariables property of this script task, according to whether or not your
         * code needs to write to the variable.  To add the variable, save this script, close this instance of
         * Visual Studio, and update the ReadOnlyVariables and 
         * ReadWriteVariables properties in the Script Transformation Editor window.
         * To use a parameter in this script, follow the same steps. Parameters are always read-only.
         * 
         * Example of reading from a variable:
         *  DateTime startTime = (DateTime) Dts.Variables["System::StartTime"].Value;
         * 
         * Example of writing to a variable:
         *  Dts.Variables["User::myStringVariable"].Value = "new value";
         * 
         * Example of reading from a package parameter:
         *  int batchId = (int) Dts.Variables["$Package::batchId"].Value;
         *  
         * Example of reading from a project parameter:
         *  int batchId = (int) Dts.Variables["$Project::batchId"].Value;
         * 
         * Example of reading from a sensitive project parameter:
         *  int batchId = (int) Dts.Variables["$Project::batchId"].GetSensitiveValue();
         * */

        string fpath;
        string fname;
        string prname;
        //int row = 0;
        int counter = 0;
        //int fieldcount;
        //int header = 0;
        DateTime startDate;
        DateTime endDate;
        SqlParameter param1 = new SqlParameter();
        SqlParameter param2 = new SqlParameter();
        
       

        #endregion

        #region Help:  Firing Integration Services events from a script
        /* This script task can fire events for logging purposes.
         * 
         * Example of firing an error event:
         *  Dts.Events.FireError(18, "Process Values", "Bad value", "", 0);
         * 
         * Example of firing an information event:
         *  Dts.Events.FireInformation(3, "Process Values", "Processing has started", "", 0, ref fireAgain)
         * 
         * Example of firing a warning event:
         *  Dts.Events.FireWarning(14, "Process Values", "No values received for input", "", 0);
         * */
        #endregion

        #region Help:  Using Integration Services connection managers in a script
        /* Some types of connection managers can be used in this script task.  See the topic 
         * "Working with Connection Managers Programatically" for details.
         * 
         * Example of using an ADO.Net connection manager:
         *  object rawConnection = Dts.Connections["Sales DB"].AcquireConnection(Dts.Transaction);
         *  SqlConnection myADONETConnection = (SqlConnection)rawConnection;
         *  //Use the connection in some code here, then release the connection
         *  Dts.Connections["Sales DB"].ReleaseConnection(rawConnection);
         *
         * Example of using a File connection manager
         *  object rawConnection = Dts.Connections["Prices.zip"].AcquireConnection(Dts.Transaction);
         *  string filePath = (string)rawConnection;
         *  //Use the connection in some code here, then release the connection
         *  Dts.Connections["Prices.zip"].ReleaseConnection(rawConnection);
         * */
        #endregion


/// <summary>
        /// This method is called when this script task executes in the control flow.
        /// Before returning from this method, set the value of Dts.TaskResult to indicate success or failure.
        /// To open Help, press F1.
        /// </summary>
public void Main()
        {
            // Read SSIS variables to local variable.
            startDate = (DateTime)Dts.Variables["User::str_StartDate"].Value;
            endDate = (DateTime)Dts.Variables["User::str_EndDate"].Value;
            fpath = (string)Dts.Variables["User::str_Fpath"].Value;
            fname = (string)Dts.Variables["User::str_Fname"].Value;
            prname = (string)Dts.Variables["User::str_Pname"].Value;


            // create dest ff connection
            string FFConn;
            FFConn = (string)(Dts.Connections["FF_DST_Details"].AcquireConnection(Dts.Transaction) as String);
            StreamWriter sw = new StreamWriter(FFConn);
            //MessageBox.Show(FFConn, "FF_DST_Details");

            // create source db connection
            SqlConnection DBConn = new SqlConnection();
            DBConn = (SqlConnection)(Dts.Connections["ADO_NET_ReportingOLTP"].AcquireConnection(Dts.Transaction) 

as SqlConnection);
            SqlDataReader sqlreader = null;
            //MessageBox.Show(DBConn.ConnectionString, "FF_DST_Details");

            //DBConn.Open();
            SqlCommand cmd = new SqlCommand(prname, DBConn);
            cmd.CommandTimeout = 300;
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.CommandText = prname;
            //MessageBox.Show(cmd.CommandText, "Stored Procedure About to execute...");
            param1.ParameterName = "StartDate";
            param1.Value = (DateTime)Dts.Variables["User::str_StartDate"].Value;
            cmd.Parameters.Add(param1);
            //MessageBox.Show(param1.ParameterName, "Parameter1 About to execute...");
            param2.ParameterName = "EndDate";
            param2.Value = (DateTime)Dts.Variables["User::str_EndDate"].Value;
            cmd.Parameters.Add(param2);
            //MessageBox.Show(param2.ParameterName, "Parameter2 About to execute...");  
            //MessageBox.Show(cmd.CommandText, "About to execute...");
            sqlreader = cmd.ExecuteReader();
            //MessageBox.Show(sqlreader.FieldCount.ToString(), "Column Count");

// log
            Dts.Events.FireInformation(0, "Info: ", "Begin process!", string.Empty,

            if (sqlreader.HasRows)
             {
                 while (sqlreader.Read())
                 {
                    counter = sqlreader.RecordsAffected;
                    sw.WriteLine(sqlreader[0]);
                 }
                 sqlreader.NextResult();
              }

                if (sqlreader!= null)
                {
                    sqlreader.Close();
                }

            //  Close the connection
            if (DBConn != null)
            {
                DBConn.Close();
            }

            Dts.TaskResult = (int)ScriptResults.Success;
            // sqlreader.Close();
            //DBConn.Close();
            sw.Close();


        }

        #region ScriptResults declaration
        /// <summary>
        /// This enum provides a convenient shorthand within the scope of this class for setting the
        /// result of the script.
        /// 
        /// This code was generated automatically.
        /// </summary>
        enum ScriptResults
        {
            Success = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Success,
            Failure = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Failure
        };
        #endregion

}
}

String data type to Date in SSIS

$
0
0
 

hi im trying to push the data of an Excel sheet to SQL table column.

my Excel is having dateofbirth column

(ex: 4/28/1965,   2/28/1986)
i want to push this column to my destination table of data type Varchar or Nvarchar

i tried dataconversion transformation but unable to push.can some one give me expression to push this.


Doing SSIS Tutorial Lesson 1 - Step 1 in SQL Server 2012 Express & SQL Server 2012 Management Studio: Cannot do it!!??

$
0
0

Hi all,

I just have Microsoft SQL Server 2012 Express and SQL Server 2012 Management Studio installed in my "Windows 7" PC.  I tried to the Microsoft SSIS Tutorial: Creating a Simple ETL Package => Lesson 1: Creating the Project and Basic Package => Step 1: Creating a New Integration Services Project:  I clicked on the Start of my PC =>All Programs => Microsoft SQL Server 2012 => SQL Server Data Tools => "Microsoft Visual Studio 2010 Shell"  program showed up => I ctreated a new project "SSIS_tut_Lesson1_Step1"  in the "Integration Services Project" section, then clicked on "OK" button.  I got the following:

I guess that my Microsoft SQL Server 2012 Express and SQL Server 2012 Management Studio cannot do the SSIS projects (via SSDT) in my PC!!!???  Am I guessing right on this matter? 

Please kindly help and advise me on this matter.

Thanks,

Scott Chang

P. S.  I also guess that Microsoft "Data Flow Task" cannot be done in my Microsoft SQL Server 2012 Express and SQL Server 2012 Management Studio either!!??  Please comment on this doing "Data Flow Task" thing too.

Viewing all 24688 articles
Browse latest View live


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