Reference For SSIS C-like Script Needed
May 19, 2006
Consider the Conditional Split task. I can use a C-like language to create statements such as
Ltrim ([Col1] =€?A€?) || Ltrim([Col1] =€?B€?)
This sure ain€™t VB-like and the list of functions in the upper right-hand pane of the task (€œexpression editor€?) does not help me construct such statements.
Where is the reference manual describing this language?
TIA,
Barkingdog
P.S. I have found fragments in BOL but the info does not seem complete and the BOL topic fragmentation impedes learning.
P.P.S. Why MS uses this language instead of VB.NET, which they use in their Script tasks, is beyond me.
View 2 Replies
ADVERTISEMENT
Jan 25, 2007
I have a .NET assembly that I need to reference and use within my SSIS script task.
The only way I can acheive this is to strongly name my assembly and put it in the GAC.
This is not possible as my assembly is already in production and uses other 3rd party assemblies that would also need to be registered in the GAC.
As a workaround, I have created a .Net console application that references my assembly, that call from a SSIS Process Task.
Does anyone know of another way I could use my .NET assembly within my SSIS package?
Any help appreciated.
Regards,
Paul.
View 3 Replies
View Related
Sep 14, 2006
I never had to use DTS in MSSQL 2000 but I'm finding a need to use SSIS quite a bit in a new position. I know this is subjective, but I looking for suggestions for a reference book with good examples and tutorials.
TIA
View 3 Replies
View Related
Feb 21, 2006
Hi, I have heard alot of people talk about using C# for scripting withing SSIS and the answer to that question is no apparently. You can only use VBA but there is no extensive or in my respect any documentation as reference for using VBA in SSIS. I am new to VBA because i used to use jscipt and vbscript in early version of sql server. But in order to learn using VBA, I need to learn it in which there seems to be no reference in relation to SSIS. All the VBA references you find are in relation to MS Office. Is there anything i am missing or can someone show me where to go as my reference for VBA in SSIS. Its bad enough to change the scripting language but worse not to provide any reference materials for uses to get up to speed.
View 3 Replies
View Related
Sep 4, 2006
Hi ALL
I cannot add the reference to the following:
"Imports Microsoft.AnalysisServices.AdomdClient"
in SSIS script task. All the objects that i declared become underlined because there is no reference to the above library.
When i go in SSIS script task and open the code to add the reference it does not the list the above library.
I am able to add reference in Visualstudio but not in SSIS.
Please adivse, it is very critical and urgent for my task
Thanks.
View 5 Replies
View Related
Apr 30, 2007
We are getting prepared to move from SQL Server 2000 to 2005. We have a lot of DTS's that will need to be converted to SSIS. Can you recommend a really good reference book or text book on SSIS that will help us out both with DTS conversions as well as SSIS development in general.
thanks
View 1 Replies
View Related
Sep 24, 2007
How can I add a reference to the Microsoft excel 2003 in the script tool in SSIS 2005? I need to automate Excel for formatting.
Thank you.
Dan
View 1 Replies
View Related
Apr 5, 2007
Is it possible to do this under SSIS 2005? How? I see I can add a reference to system.web.services.dll.. but then what?
The web service was developed in vb.net/vs.net 2005 and I have no problem adding and consuming it from a web page developed using vs.net 2005 - asp.net/vb.net.
Thanks for any help or information.
View 3 Replies
View Related
Feb 26, 2007
Hi All,
OK, so I have an SSIS package that I build using the "test" database as the destination. Now I want to execute it using another database as the destination. This is basically for an installation script where the source is always the same, an access database.
So here I have:
"C:Program Files (x86)Microsoft SQL Server90DTSBinnDTExec.exe" /file e:data_import.dtsx /CONNECTION DestinationConnectionOLEDB;""Data Source=(local);Initial Catalog=Test2DB;Provider=SQLNCLI.1;Integrated Security=SSPI;Auto Translate=False;""
Which works (sort of). It does try to import the data into "Test2DB", but what happens is all of the destination tables in the dtsx package have names like [test1db].[dbo].[tablename]
So my question is: is there a way to remove the databasename reference in the table names for all 195 tables in my database without doing it manually?
Thanks in advance.
View 7 Replies
View Related
Jun 22, 2007
Hi Guys,
I'm trying to develop an application and I have been told right here in sql server getting started forum that SSIS or DTS are the best bits.
My old post has these questions:
Code Snippet
I'm making an application. I have 2 different sites running Sql Server 2005 workgroup and sql server express.
I have a 3rd main server and what I would need to do is to get some of the data from both of these sites, merge it and save it on Main server and then generate another file which should be placed in a directory on a network.
I don't have any idea of how I would do that. Its entirely a sql server app.
One person told me its an SSIS and the other one said to investigate replication.
I have checked a bit about both. I want to give it a try.
Where can i find tutorials on both of these. Complete tutorials to develop and design it.
Thanks
Gemma
View 5 Replies
View Related
Sep 10, 2014
I am using vs 2010 to write my dtsx import scripts.I use a script component as a source to create a flat file destination file.Everything have been working fine,but then my development machine crashed and we have to install everything again.Now when i use the execute package utility to test my scripts i get the following error:
Error system.NullReferenceException: Object refrence not set to an instance reference.
In PreExecute section
TextReader = new system.io.streamreader(" file name")
In the CreateNewOutputRows:
dim nextLine as string
nextLine = textReader.ReadLine
[code]...
is there something which i did not install or what can be the error?
View 0 Replies
View Related
Jul 18, 2007
I am trying to import part of the following file structure into a SQL2005 table
The 1st 10 records are not needed (HEADER DATA), neither are the records that are from ‘TRAILER RECORD’
Can anyone assist me in designing a Simple SSIS to import this file to a table
The LedgerKey will be from a Global variable
Text within <> are for information and NOT contained in the file
In this file there are three records to be imported, but in other files thjere can be upwards of 20,000 records
Table
CREATE TABLE [dbo].[TempTransactions](
[LedgerKey] [varchar](20) NOT NULL,
[Licence] [varchar](6) NOT NULL,
[DestSortCode] [varchar](6) NOT NULL,
[DestAccountNumber] [varchar](8) NOT NULL,
[DestAccountName] [varchar](18) NULL,
[TransValue] [varchar](11) NOT NULL,
[DestBankRef] [varchar](18) NULL,
[TransCode] [varchar](2) NOT NULL,
[tranref] [int] IDENTITY(1,1) NOT NULL
) ON [PRIMARY]
File
< HEADER DATA NOT REQUIRED >
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
"Header Data"
< HEADER DATA NOT REQUIRED >
"11111122222222TEST ACCOUNT 1 BANK REG 0000000020017"
"33333344444444TEST ACCOUNT 2 BANK REG 0000000150017"
"55555566666666TEST ACCOUNT 3 BANK REG 0000000030017"
<FIXED FIELDS LENGTHS 6,8,18,18,11,2 >
<TRAILER RECORD NOT REQUIRED >
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
"TRAILER RECORD"
<TRAILER RECORD NOT REQUIRED >
View 1 Replies
View Related
May 26, 2006
I'm all mixed up on this one. Please comment on either of the following two remarks.
1. When I create a new SSIS package under BIDS I gather it is intended for development purposes. .I can test the package and run it but I need to"deploy" it (possibly to another server) to make it available for others to use.
2. Is "deploying" essentially copying my package (.ldtsx) to a new server or does it involve a lot more?
3. I read that I can create an SSIS package without actually needing to have sql 2005 installed on my box. Suppose I create a package that makes no reference to any databases. To *run* this package will I need sql2005 installed or can BIDS do this?
TIA,
barkingdog
View 3 Replies
View Related
Jul 23, 2006
If one of our SSIS packages fails because of a communication problem with the backend, and the DBA is not available, my boss wants another individual (probably a senior programmer but not an "sa" type) to be able to re-run the job.
What is the "right" way to do this under SSIS sql 2005?
TIA,
barkingdog
View 1 Replies
View Related
Sep 25, 2007
Hi i have a issue i am loading data from a flat file into a relational Database and i am loading the data without dropping the Primary and Foreign Key constraints and i am sending the error rows into a error table for each table. This is becoming large over head is there a way to Load the entire error Row as a single Column in one Error Table.
This is occuring coz the input is being parsed and its dividing into columns,
One approach would be to used Derived Column Transformation and Substring all columns but it makes to writing long substring statement as some tables have 80 columns ,
is there a better way to handle these errors so that they can be looked at and Changes can be made to the Data ,
Also one more question is is there a way to Load in case of Duplicates load only the Recent Row By Date Column.
and send the old row according to Date into Error output.
Please suggest me what approach should i go for
View 11 Replies
View Related
Jun 29, 2006
In DTS 2000 there was situation where I had to connect source and destination through a dialup connection (56k), where the transferring of data took me ages to finish, so it was not successful.
In SSIS 2005 is there is a solution?
Thank you
Cheers,
Pradeep.
View 1 Replies
View Related
Apr 4, 2008
Hi guys
I have got a set of queries to run on a table stored in my SQL Database and this query creates a new table which I export to excel for final results.
NOw I need to design an SSIS package for this query to run and to export the result in excel sheet.
I started with the control flow by adding the TSQL statements to it and then in the data flow I connected it with my database.
But when I execute it, it always gives me an error.
I have just started learning SSIS but have not been able to figure it our properly.
Could you please help me out??
Thanks
View 5 Replies
View Related
Aug 15, 2006
I created a Backup plan using the SSMS Maintenance Wizard. It created an SSIS package for me but the package didn't delete files older than, say, 3 days. So I exported that package from MSDB, added a Script task to it (to do what I needed), and imported it back into MSDB. I can open the new package under SSMS and everything looked good ... until I double-clicked the Script task. That task is simply not supported under the SSMS Maintenance Wizard. Goin in and out of that task under SSMS gave me the following errors:
"Microsoft Visual Studio Macros: The operation could not be compelted. Call was rejected by callee.".
Or the ever popular "cannot show the editor for this task'.
I was asked to "Wait for Completion" or "Switch tasks or "Cancel".
It seems the only way to delete these files is to set up a seperate SSIS job that calls my Script task sometime after the nightly backup has completed. But now the completion of the Backup job and the file deletion processes are decoupled, which is not very good. Can you offer any ideas how to handle the gracefully? (The real problem is that the SSMS Maintenance wizard does not recognize the full set of SSIS tasks. It would be nice if double-clicking on the Maintenance plan pane opened up the SSIS editor but that's for a later day.)
TIA,
barkingdog
View 2 Replies
View Related
Apr 25, 2008
Hello
I've been given the task of migrating a DTS package to SSIS (neither of which I am particularly familar with). The first job in the DTS package is to read a .ini file and set a bunch of variables. These variables are then used throughout the DTS package. After running the DTS package through the SSIS migration wizard this job turns into an execute script task and I can't see if it is still reading the .ini file. However, the only real purpose of this step is to allow different parameters to be passed in development, test, production etc. So I am thinking this whole step can be removed and effectively replaced with a package configuration (I'll probably use an XML file). My understanding is that by selecting the name/value pairs as appropriate in the XML package configuration file means this values will be passed in at runtime and achieve the same functionality. Is this the correct way to do this in SSIS, or do I still need the .ini file and variables?
Thanks for any advice on this issue.
Regards, John
View 7 Replies
View Related
Jul 27, 2006
We have an SSIS package that will be used for both our Test and Prod imports on the same server. The SSIS imports are identical expect that Test needs all connections pointing to the Test database while Prod need its connections pointing to the Prod database.
How can I change the connections, based on Test or Prod, used inside a single SSIS package? (I don't want to create two tweaked packages on the same server. If I find a bug in one of them, I have to correct it twice.)
TIA,
barkingdog
View 3 Replies
View Related
Jun 22, 2006
In visual studio 2005, I create a new Integration Services Project. It tries to create the first package by default "Package.dtsx". The "Package.dtsx[Design]" tab displays
Microsoft Visual Studio is unable to load this document
Object reference not set to an instance of an object
I try to create new SSIS package or edit an existing one (from tutorial), I get the same error in the SSIS graphical user interface tab.
Thanks for your help.
View 3 Replies
View Related
Feb 26, 2008
I've created my own posting for this. The original post was here, I apologize: http://forums.microsoft.com/forums/ShowPost.aspx?PostID=2906512&SiteID=1
According to the poster it's not possible. But there has to be some way to do it? Reflection (don't know how)?
I need to get a reference to the task host in an SSIS Task component.
Basically the scenario is this:
I have a custom task I have created. However I would like to validate that the ExecValueVariable is infact a string variable during the validate event of the task. I know how to verify its a string variable. But I can't figure out how to read what the user selected (such as User::Myvariable). The only way I've been able to figure out how to do it, but it only works if you open my custom task UI.
What I did is this:
I've implemented IDtsTaskUI and during the initialize section I wrote:
Sub Initialize(ByVal taskHost As TaskHost, ByVal serviceProvider As IServiceProvider) Implements IDtsTaskUI.Initialize
' Store the TaskHost of the task.
Me.taskHostValue = taskHost
Dim myTask As CustomTask= CType(taskHost.InnerObject, CustomTask)
myTask.myTaskHost = taskHost
End Sub
My Task is named: CustomTask. I have a public variable in my task as follows:
Public NotInheritable Class CustomTask
Inherits Task
Implements IDTSComponentPersist
Public myTaskHost As TaskHost = Nothing
Therefore I pass back the taskhost value to the CustomTask class, and voila I have it.
Problem is, this only works if the custom task calls the initialize method, and this only happens when you open the custom editor.
I then do the validation in my CustomTask class and it works fine, but myTaskHost is null/nothing until you actually open the custom task UI
How do I solve this?
View 10 Replies
View Related
Feb 6, 2004
Hi y'all
Does anybody know reference or pdf file or free e-learning on the web?
View 1 Replies
View Related
Jun 18, 2001
DECLARE Loan_cursor CURSOR FOR
SELECT Loan_No,store
FROM loan
WHERE maturity_date > '2001-04-30' and loan_no like 'ABL%'
OPEN Loan_cursor
-- Perform the first fetch.
FETCH NEXT FROM Loan_cursor
-- Check @@FETCH_STATUS to see if there are any more rows to fetch.
WHILE @@FETCH_STATUS = 0
BEGIN
Declare @LoanNo varchar(12)
** Set @LoanNo = Loan_No
-- This is executed as long as the previous fetch succeeds.
FETCH NEXT FROM Loan_cursor
END
CLOSE Loan_cursor
DEALLOCATE Loan_cursor
when l run the cursor l get the error
Server: Msg 207, Level 16, State 3, Line 15
Invalid column name 'Loan_No'.
.
If l reference it as Set @LoanNo = LoanTable.Loan_No l get the error
Server: Msg 107, Level 16, State 3, Line 15
The column prefix 'loan' does not match with a table name or alias name used in the query.
All l'm trying to do is to compare the loan number that l get from the cursor to the value in the loans table. Maybe reference is a better word
View 1 Replies
View Related
Jun 6, 2008
Hi friends,
Just i modified one sub stored procedures which is not getting affected in the main stored procedures
Create procedure main
as
begin
set nocount on
--First sp
exec Data_transfer_sp
--Second sp
Exec Clearance_sp
set nocount off
end
In data_transfer_sp,i have commented the select statement
but still iam use to the select result while execution the main sp.
Note:I have compiled the data_transfer_sp after making comment
.Txs in advance
View 3 Replies
View Related
Sep 11, 2007
Hi All ...
WITH myCTE (x,y,z) AS (SELECT x,y,z, from myTable)
SELECT x,y,sum(z) from myCTE
SELECT y,z,sum(x) from myCTE
the second SELECT fails, and says invalid object name. does the CTE go out of scope after i reference it once?
never mind the semantics of what I am SELECTing, I just want to be able to reference the CTE more than once in my SP
am I trying to use the CTE in a way that was not intended?
View 5 Replies
View Related
Sep 11, 2007
Hi All ...
WITH myCTE (x,y,z) AS (SELECT x,y,z, from myTable)
SELECT x,y,sum(z) from myCTE
SELECT y,z,sum(x) from myCTE
the second SELECT fails, and says invalid object name. does the CTE go out of scope after i reference it once?
never mind the semantics of what I am SELECTing, I just want to be able to reference the CTW more than once in my SP
am I trying to use the CTE in a way that was not intended?
View 1 Replies
View Related
Oct 15, 2007
hi ,
can any body help me that how can i use my .net dll into my rdl file.
thanks
Gorla
View 1 Replies
View Related
Feb 3, 2008
in this code ,whtat is the references of
RelationalDataSourceView
and also
what are the references of these?
OleDbConnection
OleDbCommand
OleDbDataAdapter
View 1 Replies
View Related
Nov 16, 2006
Can anyone see why I would get the 'Object Referenece not set to an instance of an object error in the following code?
It happens on this line:
MyAdapter.SelectCommand = New SqlCommand(SelectStatement, MyConnection) 'Populate the text boxes from database for alumni fields.
Dim MyAdapter As SqlDataAdapter
Dim MyCommandBuilder As SqlCommandBuilder
Dim DetailsDS As DataSet
Dim Row As DataRow
Dim SelectStatement As String = "Select ClientID,ClassYear,HouseName,CampusName,EducationMajor,GraduationDate FROM tblclient Where [ClientID]=" & _
ClientIDSent
Dim ConnectStr As String = _
ConfigurationManager.ConnectionStrings("TestConnectionString").ConnectionString
Dim MyConnection As SqlConnection = New SqlConnection(ConnectStr)
MyAdapter.SelectCommand = New SqlCommand(SelectStatement, MyConnection)
MyCommandBuilder = New SqlCommandBuilder(MyAdapter)
MyAdapter.Fill(DetailsDS, "tblClient")
Row = DetailsDS.Tables("tblClient").Rows(0)
ClassYearText.Text = Row.Item("Classyear").ToString()
HouseNameText.Text = Row.Item("HouseName").ToString()
CampusNameText.Text = Row.Item("CampusName").ToString()
EducationMajorText.Text = Row.Item("EducationMajor").ToString()
GraduationDateText.Text = Row.Item("GraduationDate").ToString()
View 2 Replies
View Related
Jan 21, 2004
Hi,
I'm looking for a good reference guide online as I am more used to mysql (and stil quite limited vocab at that)
I create table outside of a database by accident and I'm now looking for the sql syntaxt for moving tables, but I can't find it anywhere?
most simple guides don't seem to provide the syntax to do this. :(
View 11 Replies
View Related
Feb 23, 2004
does any one know any good pages to get some sql commands
and explainations thanks
View 2 Replies
View Related
Sep 20, 2000
Hi,
I am access SQL 7 via ADO in some ASP pages. My database objects were created under a user name aliased to the dbo. As a result, when I have my client logon to make a connection, I have to preface all my object references with the name of the owner, i.e., Select * from mydboname.people . Is there a way to avoid having to prefix all my transact sql statements with the owner?
thanks,
steve
View 2 Replies
View Related