Use Of SSIS In Reading And XSL File. Should I Use SSIS Or Just Straight C#

Aug 1, 2007

I need to build an asp.net/C# application to read values from an Excel spreadsheet. Once the values are read from the spreadsheet, the C# code will do some elementary statistics on the values read. Then the values read and their computations will be written to a sql server database.

My manager suggested that SSIS might be a good candidate technology for doing this type of work. Does that sound correct? My only hesitation with using SSIS is that I want to keep the application as simple as possible, so that the code can be more portable. Maybe might argument is not a good one, but maybe someone can help me out here.

Ralph

View 1 Replies


ADVERTISEMENT

Integration Services :: Reading Data File Present In A File System From A Package Deployed In SSIS DB?

Dec 4, 2014

I am trying to create and later read a data file from a package deployed in SSISDB, but it is not reading it while it is successfully creating the file. The same package when run from the file system package, runs successfully. Generating ispac and deploying in SSISDB is running for infinite time. Is it a permission issue?

View 7 Replies View Related

Reading File Content Using SSIS

Mar 5, 2007

Hi,

I have a requirement where I should be reading the file (I will use File system Task for this) and the header content. I should be able to read the header, validate and when the validation succeeds , I should start process the rest of the file.

To elaborate this further, take a sample Example. Assume that the header will have the date information. In a given folder I should read the file, will check the date (header being the first line of the file). If it matches the current date, I will start processing and on completion I will archive my files.

Can someone help me on this sample. Thanks

Regards,

Explorer

View 3 Replies View Related

Reading .Txt File Informtion By SSIS

Apr 26, 2007



Hi,



I want to read and get information of Database name, userid, password from a text file by Integration services 2005.



Please let me know..



Thanks

View 1 Replies View Related

Reading From SSIS Flat File Source?

Feb 9, 2012

I have a simple SSIS package -> It reads a local text file which has 10 rows of data ( id, name, telephone # ) and puts it into a table.

It uses the "SSIS Flat File source" to read and a "SQL Command" to insert into the table. I can see that it reads line by line and puts each line into one row in my table.

Now, my production data is over 5 GiG of mainframe data and it seems their data is arranged in some hierarchical form.. so the position or arrangement of data in that file is important.

I pulled the data using my package and as far as I can see , my SSIS package pulled one line at a time ( from the flat file) and pushed it into my table. For each row, I also created an identity column in my table to be able to identify the positional arrangement of the hierarchical data and then use relational mappings to suit our business needs.

In all of this, my assumption is -

"SSIS reads one line at a time, inserts to my table and goes down to the next line .

It does NOT read a snapshot of rows from the flat file so as to write them into the table using internal ordering methods based on that particular snapshot "

My question is .. is my assumption correct ?

View 1 Replies View Related

SQL 2012 :: Reading From Excel File Into SSIS?

Nov 17, 2014

I have an excel file which i am reading through SSIS through MICROSOFT Office 12.0 Access Database Engine OLE DB Provider. My problem is that if the Excel file has data in a column as 123.45 which is displayed as 123. SSIS is able to pick 123 only and not 123.45. however if I change the data type to Numeric in the excel, SSIS is able to read data as 123.45.Any solution other than changing data type in Excel?

View 2 Replies View Related

SQL 2012 :: Reading File From Sharepoint To SSIS

Dec 16, 2014

We have a requirement to read data from Sharepoint to SSIS. Is it doable? What components to use and any dll we should include.

View 1 Replies View Related

SSIS: Excel Import: SSIS Not Reading Dates

Apr 26, 2008

Hi. I need to import excel file in database. i first need to do an unpivot task. the column names are dates and SSIS seems to be unable to pick up the column name as it is replaced by F2 F3 F4etc Can you advise of a solution. thanks ken

View 1 Replies View Related

Reading Pdf Files With SSIS 2005

Sep 14, 2006

hello to everyone, i would like to ask u if you know how can i import pdf files in sql server integration services 2005? does anyone have a script ???

thank u

View 7 Replies View Related

SSIS Script Task Reading Variables In Vb.net DTS

Dec 15, 2006

I'm trying this code in a script task inside a foreach loop that gets a file in a foreach file enumerator and maps it to a variable FileName.
 In the script task I'm setting the ReadOnlyVariables to @[User::FileName]
: Imports System.IO Imports System Imports System.Data Imports System.Math Imports Microsoft.SqlServer.Dts.Runtime
Public Class ScriptMain
    Public Sub Main()         Dim fname As String = CType(Dts.Variables("FileName").Value, String)         File.Move(fname, fname + ".processed")         Dts.TaskResult = Dts.Results.Success     End Sub
End Class
But now getting this error:
Error: Failed to lock variable "\xxxxDataf1.csv" for read access with error 0xC0010001 "The variable cannot be found. This occurs when an attempt is made to retrieve a variable from the Variables collection on a container during execution of the package, and the variable is not there. The variable name may have changed or the variable is not being created.".
 
As you can see the variable does appear to be resolving.

View 1 Replies View Related

SSIS Package : Reading XML Data In VB Script

Oct 15, 2007

Hi Guys,

I have to read a database column in my VB script which basically contains XML data. My requirement is to read that column and then retrieve couple of nodes within that dataset and then based on those values ....i have to execute a procedure....


Can anyone please let me know how to traverse a XML document in VB Script

Thanks......

View 2 Replies View Related

ASP.NET Reading Package List From Remote SSIS Server

Feb 14, 2008

Hi everyone!

I have a question regarding ASP.NET 2.0 reading available packages (calling "GetDtsServerPackageInfos" on the "Application"-Object which returns "Microsoft.SqlServer.Dts.Runtime.PackageInfos") from a remote SSIS server (not running them). It seems to me that I am experiencing either a security/delegation issue or that I am trying to do something that is not possible...

The setup is the following.

I have two machines, A and B. A runs IIS 6/ASP.NET 2.0 and B runs SQL Server and SSIS. They belong to the same domain. IIS runs the application pool with the webapplication in question under the "Network Service" account and A is trusted for delegation to B. At the moment its trusted when using Kerberos and for MSSQLSrvc and rpcss; but I tried "all" and many more as well.

I configured IE to use Windows Authentication and set the URL to belog to the Intranet (to enable kerberos authentication).

My ASP.NET webapplication now tries to read (in the sense explained above) the available packages on the SSIS machine (B). The packages are stored on the filesystem, not in mdsb. But I feel that this does not matter, since ASP.NET is accessing them through "the SSIS service" which can access packages in msdb or/and on the filesystem?

What happens now is that

a) everything works, when I fire up IE on A and access the webapplication. The user I have on A is a local admin.
b) I get "E_ACCESSDENIED" when I start IE as regular User on A
c) I get "E_ACCESSDENIED" when I access the webapplication from any other machine than A (IE6 or IE7)

My main question is: is it possible to do what I want to do? The other question is, why does everything work when I access the webapplication from A, but not from any other machine? The second thing makes me think it could be a delegation issue (double hop and SSIS don't seem to go togethe too well). But still, I could not find any resource telling me that this is impossible And frankly, I do not fully understand delegation and/or Kerberos.


I would greatly appreciate if anybody had a pointer or something for me.
Regards
scherand

Btw: Thanks to Caddre for his (her?) first help and pointing me to this forum.

View 20 Replies View Related

SSIS - Get ServerName From A XML Or TXT File Into SSIS Package

Jan 4, 2008

Dear Friends,
I store several configurations in the main database of my SSIS packages. I need to get the servername from a xml or txt file in order to get those configurations stored in my database.
How you think is the better way to do that?
Using a FlatFileSource to read the file and a script to save the value into a SSIS variable?
Using the package configuration I cant do that... maybe I dont know, but I can save the SSIS variale in the configuration file, but what I need is to do the inverse, read the configuration file and save the value in the SSIS variable.
How the best way you suggest?!
Regards!!
Thanks.

View 18 Replies View Related

Problem In Reading Cell Comments From A Excel Sheet Using SSIS

Nov 8, 2006

Hi,

I have created an ssis package, am using Script task to read all the cell values and comments.

In server MS Excel is not installed, so we use regsvr32 to register excel.dll ( also tried with Microsoft.Office.Tools.Excel.dll ), while doing the registration we got error as

"Registration not done, enrty point not found"

Sice the registration is not done we where unable to create the excel object in our script task.

Can anybody give as any clue, all helps are welcome.

Thanks in advance

Ezaz Mohamed

View 3 Replies View Related

Integration Services :: Excel Reading In SSIS Script Task

Jul 23, 2015

I used the below code to read excel files  in SSIS 2008R2 script component and it is working fine but when i copied it in Script Task of SSIS 2012, the code doesnt work. I have define one variable

Var_ExcelFileName and stored location of excel file.

/* Microsoft SQL Server Integration Services Script Component
* Write scripts using Microsoft Visual C# 2008.
* ScriptMain is the entry point class of the script.*/

using System;
using System.Data;
using Microsoft.SqlServer.Dts.Pipeline.Wrapper;
using Microsoft.SqlServer.Dts.Runtime.Wrapper;

[Code] ....

 I am getting errors in the below lines:

using Microsoft.SqlServer.Dts.Pipeline.Wrapper;
using Microsoft.SqlServer.Dts.Runtime.Wrapper;

And Also in this line:

dt = LoadWorkbook(Variables.VarExcelFileName,
"Sheet1");

View 6 Replies View Related

Integration Services :: Reading 500 Columns In Excel Sheet Using SSIS

Nov 17, 2010

I have to transform 500 columns from an excel sheet to Sql Server. In Excel 2k3 , I can read a max of 256 columns only.If I use Excel 2k7, then SSIS 2k5 excel source does not support excel 2k7. If I use ole db source then again it can read a max of 256 columns.how can we read 500 columns in excel sheet (Around 10000 rows) efficiently using SSIS 2k5.   

View 12 Replies View Related

SQL Server 2005 Integration Service (SSIS) Reading HTTP Data

Jan 16, 2008



I need to read in general web pages (not a web service) from a typical web site using SSIS and make it available for other SSIS transformations (Script Component). I tried using the XMLSource data source but this appears to require well formed XML, and will not accept HTML which is what I am likely to be getting from the web pages.
I tried a HTTP Connection Manager with a DataReader Source, but seems to only accomodate web services.

Can this be done? If someone has an example (tutorial) of how to accomplish this I would greatly appreciate a copy.
James

View 1 Replies View Related

Read Text File From Flat File Connection Manager SSIS

May 13, 2008

Hello Experts,
I am createing one task (user control) in SSIS. I have property grid in my GUI and 2 buttons (OK & Cancle).
PropertyGrid has Properties like SourceConnection, OutputConnection etc....right now I am able to populate Connections in list box next to Source and Output Property.

Now my question to you guys is depending on Source Connection it should read that text file associated with connection manager. After validation it should pick header (first line of text file bases on record type) and write it into new file when task is executed. I have following code for your reference. Please let me know I am going in right direction or not..
What should go here ?
->Under Class A

public override DTSExecResult Execute(Connections connections, VariableDispenser variableDispenser, IDTSComponentEvents componentEvents, IDTSLogging log, object transaction)

{

//Some code to read file and write it into new file

return DTSExecResult.Success;

}


public const string Property_Task = "CustomErrorControl";

public const string Property_SourceConnection = "SourceConnection";



public void LoadFromXML(XmlElement node, IDTSInfoEvents infoEvents)

{

if (node.Name != Property_Task)

{

throw new Exception(String.Format("Invalid task element '{0}' in LoadFromXML.", node.Name));

}

else

{

try

{



_sourceConnectionId = node.Attributes.GetNamedItem(Property_SourceConnection).Value;



}

catch (Exception ex)

{

infoEvents.FireError(0, "LoadFromXML", ex.Message, "", 0);

}

}

}

public void SaveToXML(XmlDocument doc, IDTSInfoEvents infoEvents)

{

try

{

// // Create Task Element

XmlElement taskElement = doc.CreateElement("", Property_Task, "");

doc.AppendChild(taskElement);

// // Save source FileConnection

XmlAttribute sourcefileAttribute = doc.CreateAttribute(Property_SourceConnection);

sourcefileAttribute.Value = _sourceConnectionId;

taskElement.Attributes.Append(sourcefileAttribute);

}

catch (Exception ex)

{

infoEvents.FireError(0, "SaveXML", ex.Message, "", 0);

}

}

In UI Class there is OK Click event.

private void btnOK_Click(object sender, EventArgs e)

{

try

{



_taskHost.Properties[CustomErrorControl.Property_SourceConnection].SetValue(_taskHost, propertyGrid1.Text);

btnOK.DialogResult = DialogResult.OK;

}

catch (Exception ex)

{

Console.WriteLine(ex);

}

#endregion

}

View 10 Replies View Related

How To Specify Multiple File Types In SSIS Foreach Loop (File Enumerator)?

May 2, 2007

I want to enumerate all *.xls and *.csv file. How to fill the Files box? I tried

*.xls, *.csv

*.xls *.csv

*.(xls|cvs)

all doesn't work

View 4 Replies View Related

SSIS - Data Flow To Flat File - Insert At Start Of File

Oct 24, 2007

Hi all,

In a foreachloop, I am inserting records into a flat file which is working fine. But the thing is that as the file grows, it takes longer for it to locate the EOF(End of File) of the flat file so as to insert the records.

I have around 70-100 lines written to the file at each loop and there are more than 20k records to be looped. wihich means that at the end I should be having 1400k - 20000k line in the text file.


One solution would be to insert the records at the start of the file itself so that it does not has to lookup the EOF each time before writting.

Another would be to generate separate files and then merge it.

Any idea how can this can be done?


Beside this I have to zip the file and then SFTP to a given address.

Any suggestion or help would be welcome.


Rdgs

David



View 5 Replies View Related

SQL Server 2008 :: SSIS Copy File From SharePoint Library Using File System Task Permissions?

Jun 19, 2015

Historically I've always written a VB script to copy a file from a sharepoint library. I don't like this method because I have to input a username & password in the script and maintain a config file.

Yesterday I was playing around with using a file system task. The sharepoint file has a UNC path so why not? I created a simple test package with a single file system task that copies the sharepoint file (addressed via UNC) to another network location. Package runs fine locally.

I try running on our utility server but am getting a "The file name [SHAREPOINT UNC PATH] specified in the connection was not valid" error. Package is running with a proxy on the server and the proxy account has the same permissions to the sharepoint site (so far as I can tell) as me.

View 0 Replies View Related

How Can Unzip File Text File Using SSIS

Oct 1, 2006



Hi,

I am pulling text files in gzip format from UNIX system. I want to unzip these files and then import data from these files into database using SSIS.

View 15 Replies View Related

SSIS Log File Name

Jan 30, 2008

Originally in my DTS, the logfilename property is assign by a variable in a dynamic properties task.

After migrate, it appear commented in the script task. So may i know how can i assign the logfilename with the variable value?

Please advice, thank you.

View 2 Replies View Related

Using .ds File In SSIS

May 29, 2007

Hello,

Can we keep a database connection information in .ds (datasource) files. Is it possible to use these instead of the standard approach of putting the connection string in the configuration file.

Furthermore, when they run the SSIS package from the command line (using DTEXEC), is it possible to pass the .ds file as a parameter?

View 4 Replies View Related

SSIS And XML File

Apr 22, 2008

Hi,

I am using an XML source component to integrate it into an SQL server data base.My problem is that when I try to open my data flow containing the XML source component, it take much time to open it, so I don't know why beacause I have a very good machine with 2GO of RAM. is it a problem of SSIS with XML files?

thank you in advance

View 8 Replies View Related

How To Rename A File In SSIS

Sep 26, 2006

I want to rename a file that is a variable to a fixed file name in a specific folder in SQL Server System Integration Services using the File System Task Editor. Example: File1.txt to Users.txt or File2 to Users.txt.    The source file is a variable the destination file is not. Here is an example of the File System Task EditorHOW DO I SPECIFY A FIXED OR VARIABLE FOLDER NAME WITH A SPECIFIC FILE NAME?????????File System Task EditorProperties                              ValueDestination ConnectionIsDestinationPathVariable       TrueDestinationVariable                User::ArchivePathOverWriteDestination              TrueGeneralName                                    Rename a fileDescription                            File System TaskOperationOperation                             Rename fileSource ConnectionIsSourcePathVariable           TrueSourceVariable                     User::ImportFilePath Thanks

View 1 Replies View Related

[help] SSIS File Configuration (XML)

Apr 3, 2007

We are deploying our SSIS packages into different folders. For example:
Test1
est2
production

Test1 points to the Test1 database, etc.

So, I configured my SSIS package to use a database connection called dbMAIN.

I then setup the SSIS File Configuration (XML) so that "dbMain" points to Test1. This xml file, called Global.dtsConfig, sits in C: est1, the same place as my ssis.dtsx file.

I want to copy my dtsx file and my dtsconfig file into est2 and production. The problem is that the the location of dtsconfig is HARDCODED in the ssis package!

How do I dynamically change it?

I tried to hardcode the location to ".Global.dtsconfig", but that did not work! Please advise!

View 1 Replies View Related

URL File Download From SSIS

May 28, 2013

have a URL that I get from a partner by calling another URL and feeding it some query parameters. That call returns to me a URL which is what I need to then go get the file I'm downloading. I have no problem getting that URL into a variable in my SSIS package. URL....there are several key-value pairs after that question mark which denote the login information, the report ID that it's picking up, etc.

If I manually take that URL and dump it into IE and hit enter, I get the standard "Open/Save/Cancel" prompt. If I open it, I see the XML that should be in my file in the browser. If I save it, I get the standard save dialoge box so that I can save the xml file.How do I do this in SSIS? I can create a file connection for where I want this XML file to be saved, but I don't see an option in the XML task to simply save the file from a URL.

View 2 Replies View Related

Zipped File On SSIS

Mar 14, 2007

Hi,

I need to zipped files using SSIS, but not sure how to do that.
Zip application: 7-zip

Any help?

thanks

View 1 Replies View Related

SSIS Hangs On .Bat File

Mar 30, 2007

I am encountering a weird issue with SSIS.

I have a very simple SSIS package that executes a .bat file. Here's
the
actual file it executes:


@Echo Off
c:
F:
cd ReportingServicesScripts
rs -i NoteBlankSnapshots.rss -S http://10.90.160.13/ReportServerTest
EXIT


The .bat file executes a Reporting Services .rss script using the
rs.exe
utility. When I run the command from the http://10.90.160.13/ReportServerTest
EXIT


The .bat file executes a Reporting Services .rss script using the
rs.exe
utility. When I run the command from the command prompt, it runs just
fine.
When I execute the .bat file manually, it runs and completes. When I
execute
the actual package, it also completes. But when I schedule the package
as a
job, it just hangs...it never finishes.


The owner of the job is an administrator in SQL Server. I have the
SQL
Server Agent configured to interact with the desktop - although
my .bat file
requires no input from the user.


I've created other jobs that just execute plain old SQL using the
same
owneer and these jobs complete just fine.


What am I missing?


Any help would be appreciated!


Thanks!!
__________________
Anthony Robinson

"If I'm curt with you, it's because time is a factor here. I think fast, I talk fast, and I need you guys to act fast if you want to get out of this. So, pretty please - with sugar on top..."

View 11 Replies View Related

Importing XML File Using SSIS (DTS)

Mar 3, 2006

I can use MS Access to import an XML file and it builds the columns and loads the data. I am trying to use SQL Server 2005 to do the same thing and there doesn't seen to be a way to easily accomplish the same task that works so well in Access.

Has anyone tried this? If so and you were successful, what were the steps to set up the package?



Thanks.

View 6 Replies View Related

Dling Xml File Over SSIS Possible?

Mar 24, 2006

i need to download a file over HTTP and get a xml file then upload it into SSIS.

Only 2 methods are available in SSIS:  FTP and web method. How come there is no HTTP transfer task in SSIS? pretty strange.

then i found a script at

http://www.sqljunkies.com/howto/49e823fd-d126-4134-893d-1fd8bd3bd3ba.scuk

 

What kind of SSIS tasks do i need to perform this operation? I got the script above but I don't know where to key it in.

 

 

 

View 4 Replies View Related

Usage Of Raw File In SSIS

May 31, 2006

What is raw file in SSIS, could you tell me samples for usage of raw file

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved