Create Excel File Dynamically for Stored Procedure Results in SSIS Package by using Script Task-P165

Create Excel File Dynamically for Stored Procedure Results in SSIS Package by using Script Task-P165

TechBrothersIT

8 лет назад

16,118 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

@sravstv8896
@sravstv8896 - 24.09.2023 10:09

i am retriving data from SQL Query it has some joins with different tables how can i use this in script task

Ответить
@jewelc2770
@jewelc2770 - 03.08.2023 09:28

Excellent video! What version of VS are you using?

Ответить
@leaderkidtaeyeon179
@leaderkidtaeyeon179 - 13.12.2022 18:03

trying to create this one.but, why suddenly errorand log.txt send the result with "System.NullReferenceException: Object reference not set to an instance of an object.
at ST_b9d46565e3754868b3b7ff43bdfde09c.ScriptMain.Main()"

what's that mean ? please help

Ответить
@DnD64
@DnD64 - 10.09.2022 16:39

Very useful, nicely presented.👍

Ответить
@AchuVlogs
@AchuVlogs - 06.11.2021 21:11

Hi sir. Very helpful video. Can you show how to export from multiple tables to different sheets in the same workbook?

Ответить
@RonaldKaylorPhoto
@RonaldKaylorPhoto - 28.07.2021 21:39

Great format and simple to follow with plenty of details - Thanks. I am new to this so I tried to follow along and I am getting the follow error. any suggestions? System.InvalidOperationException: Fill: SelectCommand.Connection property has not been initialized.
at System.Data.Common.DbDataAdapter.GetConnection3(DbDataAdapter adapter, IDbCommand command, String method)
at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
at ST_b9b0ce053b4249359fdbd25b9a37dfbf.ScriptMain.Main()

Ответить
@shahbazkhan3034
@shahbazkhan3034 - 05.10.2020 22:16

It was very helpful indeed. Thanks for sharing this.

Ответить
@devenshah3653
@devenshah3653 - 07.08.2020 21:55

I am looking to do this but gives me following errors:
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)
at Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTATaskScriptingEngine.ExecuteScript()

Script build has no error and I did change the connection name.

Ответить
@umacalopsitaeumviolao
@umacalopsitaeumviolao - 16.10.2019 17:37

i'm using 2017 version of Visual Studio, I can't seem to find neither user folder path nor user excel

Ответить
@pikenren7884
@pikenren7884 - 27.09.2019 11:51

Great tutorial, but I am having timeout error in script task, running SP that runs for 6min, but it stops after 30s I tried adding this line to script, but it did not work.
DataSet ds = new DataSet();
adapter.Fill(ds);
adapter.SelectCommand.CommandTimeout = 1800;
Do you know how to upgrade this script to not have timeout error

Ответить
@richsanders7742
@richsanders7742 - 26.02.2019 17:44

Another excellent tutorial. Thanks.

Ответить
@pankajvats6677
@pankajvats6677 - 22.05.2018 13:11

Good Job :)

Ответить
@KW.30
@KW.30 - 17.11.2017 01:28

This is very helpful video, however the export data type are all text, could you please advise how do convert all datatype from text to neccessary format?

Ответить
@saurabhbijagare7814
@saurabhbijagare7814 - 06.09.2017 14:57

could you please tell me how to use parameters of stored procedures in script task?

Ответить
@argyrodriguez5458
@argyrodriguez5458 - 31.10.2016 15:01

I find your post very relevant and easy to understand. I have used some of them in solving my problems. I have found one to read a CSV file and produce an Excel file, which I found very useful. One I have not found in your series is the formatting of an existing Excel file using a script task , by coloring some column headers; and re-saving the same Excel file. I have found some scripts in MSDN Microsoft pages where a Foreach loop is used along with a script task, but it has not worked for me. Do you have a SSIS example to reformat Excel files? Or a script task t do? Thanks in advance

Ответить