# Inserting data to SQL table

**URL:** <https://forums.powershell.org/t/inserting-data-to-sql-table/8916>\
**Category:** PowerShell Help\
**Created:** [June 27, 2017, 11:37pm UTC](https://forums.powershell.org/t/inserting-data-to-sql-table/8916 "2017-06-27T23:37:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![venkata-kalyan](https://avatars.discourse-cdn.com/v4/letter/v/b3f665/32.png) [@venkata-kalyan](https://forums.powershell.org/u/venkata-kalyan)\
**Post date:** [June 27, 2017, 11:37pm UTC](https://forums.powershell.org/t/inserting-data-to-sql-table/8916/1 "2017-06-27T23:37:06Z")

</div>

Hi,  
I have a table in SQL named: abc & columns as “Aggregation Start Time, Aggregation End Time, Time Taken for whole process”.

I have text file with below data:  
Aggregation Start Time - 2017-06-27 22.30.00  
Aggregation End Time - 2017-06-28 01.25.35  
Time taken for whole process - 10288

It has to dump the data in text file to abc table as per the column names.

I tried lot of the things & it did not help. Can someone guide me on this.

-Kalyan

---

<div class="post-metadata">

**Author:** ![curtis-smith](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.powershell.org/curtis-smith/32/121_2.png) [@curtis-smith](https://forums.powershell.org/u/curtis-smith)\
**Post date:** [June 28, 2017, 8:12am UTC](https://forums.powershell.org/t/inserting-data-to-sql-table/8916/2 "2017-06-28T08:12:40Z")

</div>

Don Jones made a nice little powershell module for posting data to SQL. You should check out “Ditch Excel: Historical and Trend Reports with PowerShell and SQL Server” in the eBooks section.

---

<div class="post-metadata">

**Author:** ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)\
**Post date:** [May 16, 2024, 8:38pm UTC](https://forums.powershell.org/t/inserting-data-to-sql-table/8916/3 "2024-05-16T20:38:31Z")

</div>


