Viewing 15 posts - 121 through 135 (of 391 total)
I checked the column count in SQL Server table and it matches the number of csv columns.
May 11, 2021 at 4:15 pm
I'm not sure but the package fails if the comma is not there.
May 11, 2021 at 3:52 pm
Maybe I'm approaching this all wrong - the problem is my csv files will not load unless there's a comma at the end of each row. So maybe there's a...
May 11, 2021 at 3:41 pm
This line has to reference the file name as a literal: string[] lines = File.ReadAllLines("items.txt")....set up as a variable?:
public void UpdateInFile(string modified,int id)
...
May 11, 2021 at 3:30 pm
Something like this? I know this as written will not work:
StringWriter csv = new StringWriter();
csv.WriteLine(string.Format("{,},{LF}"));
foreach (var item in YourListData)
{
csv.WriteLine(string.Format("{,},{LF}));
}
return File...
May 11, 2021 at 3:11 pm
I was able to get this to work:
using System.IO;
namespace ST_adc7961e6d564b959438804fe590a5a4
{
[Microsoft.SqlServer.Dts.Tasks.ScriptTask.SSISScriptTaskEntryPointAttribute]
public partial class ScriptMain : Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase
{
public void Main()
...
May 7, 2021 at 4:52 pm
And put the DOS "Move" command into the script above... I'm not following that.
May 7, 2021 at 4:13 pm
I like the idea of using C# but know very little of the language.... so I want to move the entire contents (several .csv files) of one folder into another......
May 7, 2021 at 3:45 pm
Thanks! that solved the problem... I added the headers which avoided the errors
May 5, 2021 at 4:30 pm
I solved the above by simply changing the datatype in SQL Server table to NVARCHAR... again thanks for all the help!
April 20, 2021 at 5:33 pm
I created a parameter and gave it a value. Can I use my existing Derived Column to pass the parameter's value into one of my SQL fields? I gave it...
April 20, 2021 at 5:08 pm
Also if I wanted to pass a literal string to a SQL field via SSIS do I just add another variable and assign the literal value to pass in with...
April 20, 2021 at 4:38 pm
Currently in the package it is mapping to NVARCHAR(50) but what if I wanted to map to a field that had DATE datatype?
April 20, 2021 at 4:06 pm
One more thing I changed my expression to (DT_Date)(LEFT(RIGHT(@[User::FileNameDate],14),10)) to convert to a date but it returns format like: 3/31/2021 (?) Are there other ways to convert the date?
April 20, 2021 at 3:57 pm
Thanks! I was able to put in the formula in a Derived Column Transformation account for the extension with LEFT(RIGHT(@[User::FileNameDate],14),10).
April 20, 2021 at 2:47 pm
Viewing 15 posts - 121 through 135 (of 391 total)