<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: SQL 2005: SSIS &#8211; Pushing Data to MySQL using Script Component Destination</title>
	<atom:link href="http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/</link>
	<description>Homepage of Steve Novoselac</description>
	<lastBuildDate>Fri, 12 Mar 2010 15:59:49 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: swgr</title>
		<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/comment-page-1/#comment-160546</link>
		<dc:creator>swgr</dc:creator>
		<pubDate>Sat, 12 Dec 2009 12:26:41 +0000</pubDate>
		<guid isPermaLink="false">http://blog.stevienova.com/?p=1336#comment-160546</guid>
		<description>Trying to get this to work...only using a single variable initially and I continue to get the following:&lt;br&gt;&lt;br&gt;[DTS.Pipeline] Warning: The output column &quot;PlayerID&quot; (1949) on output &quot;Output 0&quot; (1193) and component &quot;IQC Player&quot; (1170) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance. &lt;br&gt;&lt;br&gt;Thought I followed all steps correctly, but must be missing something.  Here is the script code:&lt;br&gt;&lt;br&gt;&#039; Microsoft SQL Server Integration Services user script component&lt;br&gt;&#039; This is your new script component in Microsoft Visual Basic .NET&lt;br&gt;&#039; ScriptMain is the entrypoint class for script components&lt;br&gt;&lt;br&gt;Imports System&lt;br&gt;Imports System.Data&lt;br&gt;Imports System.Math&lt;br&gt;Imports Microsoft.SqlServer.Dts.Pipeline.Wrapper&lt;br&gt;Imports Microsoft.SqlServer.Dts.Runtime.Wrapper&lt;br&gt;Imports System.Data.Odbc&lt;br&gt;&lt;br&gt;Public Class ScriptMain&lt;br&gt;    Inherits UserComponent&lt;br&gt;&lt;br&gt;    Dim mySQLConn As OdbcConnection&lt;br&gt;    Dim sqlCmd As OdbcCommand&lt;br&gt;&lt;br&gt;    Public Overrides Sub AcquireConnections(ByVal Transaction As Object)&lt;br&gt;        mySQLConn = CType(Me.Connections.IQModel.AcquireConnection(Nothing), OdbcConnection)&lt;br&gt;    End Sub&lt;br&gt;&lt;br&gt;    Public Overrides Sub Input0_ProcessInputRow(ByVal Row As Input0Buffer)&lt;br&gt;&lt;br&gt;        sqlCmd = New OdbcCommand(&quot;INSERT INTO IQC_Player on duplicate key update PlayerID=&quot; &amp; Row.PlayerID &amp; &quot;&#039;)&quot;, mySQLConn)&lt;br&gt;        sqlCmd.ExecuteNonQuery()&lt;br&gt;&lt;br&gt;    End Sub&lt;br&gt;&lt;br&gt;    Public Overrides Sub ReleaseConnections()&lt;br&gt;        Me.Connections.IQModel.ReleaseConnection(mySQLConn)&lt;br&gt;    End Sub&lt;br&gt;End Class&lt;br&gt;&lt;br&gt;Any help is greatly appreciated.</description>
		<content:encoded><![CDATA[<p>Trying to get this to work&#8230;only using a single variable initially and I continue to get the following:</p>
<p>[DTS.Pipeline] Warning: The output column &#8220;PlayerID&#8221; (1949) on output &#8220;Output 0&#8243; (1193) and component &#8220;IQC Player&#8221; (1170) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance. </p>
<p>Thought I followed all steps correctly, but must be missing something.  Here is the script code:</p>
<p>&#39; Microsoft SQL Server Integration Services user script component<br />&#39; This is your new script component in Microsoft Visual Basic .NET<br />&#39; ScriptMain is the entrypoint class for script components</p>
<p>Imports System<br />Imports System.Data<br />Imports System.Math<br />Imports Microsoft.SqlServer.Dts.Pipeline.Wrapper<br />Imports Microsoft.SqlServer.Dts.Runtime.Wrapper<br />Imports System.Data.Odbc</p>
<p>Public Class ScriptMain<br />    Inherits UserComponent</p>
<p>    Dim mySQLConn As OdbcConnection<br />    Dim sqlCmd As OdbcCommand</p>
<p>    Public Overrides Sub AcquireConnections(ByVal Transaction As Object)<br />        mySQLConn = CType(Me.Connections.IQModel.AcquireConnection(Nothing), OdbcConnection)<br />    End Sub</p>
<p>    Public Overrides Sub Input0_ProcessInputRow(ByVal Row As Input0Buffer)</p>
<p>        sqlCmd = New OdbcCommand(&#8220;INSERT INTO IQC_Player on duplicate key update PlayerID=&#8221; &#038; Row.PlayerID &#038; &#8220;&#39;)&#8221;, mySQLConn)<br />        sqlCmd.ExecuteNonQuery()</p>
<p>    End Sub</p>
<p>    Public Overrides Sub ReleaseConnections()<br />        Me.Connections.IQModel.ReleaseConnection(mySQLConn)<br />    End Sub<br />End Class</p>
<p>Any help is greatly appreciated.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve</title>
		<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/comment-page-1/#comment-160504</link>
		<dc:creator>Steve</dc:creator>
		<pubDate>Fri, 23 Oct 2009 18:15:57 +0000</pubDate>
		<guid isPermaLink="false">http://blog.stevienova.com/?p=1336#comment-160504</guid>
		<description>not sure, works fine on mine, I just tried it again. Are you sure you have the MySQL odbc stuff all installed correctly?</description>
		<content:encoded><![CDATA[<p>not sure, works fine on mine, I just tried it again. Are you sure you have the MySQL odbc stuff all installed correctly?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Cos</title>
		<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/comment-page-1/#comment-160503</link>
		<dc:creator>Cos</dc:creator>
		<pubDate>Fri, 23 Oct 2009 18:11:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.stevienova.com/?p=1336#comment-160503</guid>
		<description>I can&#039;t get pass the following error that shows when I try to build:&lt;br&gt;&quot;Error	1	Validation error. Data Flow Task: Script Component [108]: System.InvalidCastException: Unable to cast object of type &#039;MySql.Data.MySqlClient.MySqlConnection&#039; to type &#039;System.Data.Odbc.OdbcConnection&#039;.     at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.HandleUserException(Exception e)     at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.AcquireConnections(Object transaction)     at Microsoft.SqlServer.Dts.Pipeline.ManagedComponentHost.HostAcquireConnections(IDTSManagedComponentWrapper90 wrapper, Object transaction)	Package.dtsx	&quot;</description>
		<content:encoded><![CDATA[<p>I can&#39;t get pass the following error that shows when I try to build:<br />&#8220;Error	1	Validation error. Data Flow Task: Script Component [108]: System.InvalidCastException: Unable to cast object of type &#39;MySql.Data.MySqlClient.MySqlConnection&#39; to type &#39;System.Data.Odbc.OdbcConnection&#39;.     at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.HandleUserException(Exception e)     at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.AcquireConnections(Object transaction)     at Microsoft.SqlServer.Dts.Pipeline.ManagedComponentHost.HostAcquireConnections(IDTSManagedComponentWrapper90 wrapper, Object transaction)	Package.dtsx	&#8220;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve</title>
		<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/comment-page-1/#comment-160495</link>
		<dc:creator>Steve</dc:creator>
		<pubDate>Sat, 10 Oct 2009 13:51:09 +0000</pubDate>
		<guid isPermaLink="false">http://blog.stevienova.com/?p=1336#comment-160495</guid>
		<description>not sure, is there an ODBC driver? then you can use it as source connection.</description>
		<content:encoded><![CDATA[<p>not sure, is there an ODBC driver? then you can use it as source connection.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mat</title>
		<link>http://blog.stevienova.com/2009/10/07/sql-2005-ssis-pushing-data-to-mysql-using-script-component-destination/comment-page-1/#comment-160494</link>
		<dc:creator>Mat</dc:creator>
		<pubDate>Sat, 10 Oct 2009 01:24:02 +0000</pubDate>
		<guid isPermaLink="false">http://blog.stevienova.com/?p=1336#comment-160494</guid>
		<description>Will this approach work for a non SQL server data source? I have a mumps DB which I need to extract data from and load into SQL Server</description>
		<content:encoded><![CDATA[<p>Will this approach work for a non SQL server data source? I have a mumps DB which I need to extract data from and load into SQL Server</p>
]]></content:encoded>
	</item>
</channel>
</rss>
