Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion reference/5.1/Microsoft.PowerShell.Utility/ConvertFrom-Csv.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: Microsoft.PowerShell.Commands.Utility.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Utility
ms.date: 11/29/2022
ms.date: 11/18/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/convertfrom-csv?view=powershell-5.1&WT.mc_id=ps-gethelp
schema: 2.0.0
title: ConvertFrom-Csv
Expand Down Expand Up @@ -147,6 +147,31 @@ When the **UseCulture** parameter is used, be sure that the current culture's de
separator matches the delimiter used in the CSV strings. Otherwise, `ConvertFrom-Csv` can't
generate objects from the CSV strings.

### Example 5: Convert CSV data in W3C Extended Log Format

This example shows how to convert CSV data in W3C Extended Log Format to objects.

```powershell
$logData = @"
#Version: 1.0
#Fields: time,cs-method,cs-uri
00:34:23,GET,/foo/bar.html
12:21:16,GET,/foo/bar.html
12:45:52,GET,/foo/bar.html
12:57:34,GET,/foo/bar.html
"@
ConvertFrom-Csv $logData
```

```Output
time cs-method cs-uri
---- --------- ------
00:34:23 GET /foo/bar.html
12:21:16 GET /foo/bar.html
12:45:52 GET /foo/bar.html
12:57:34 GET /foo/bar.html
```

## PARAMETERS

### -Delimiter
Expand Down Expand Up @@ -257,6 +282,12 @@ In CSV format, each object is represented by a character-separated list of the p
the object. The property values are converted to strings, using the `ToString()` method of the
object. There is no way to export the methods of the object.

`ConvertFrom-Csv` also supports the W3C Extended Log format. Lines starting with the hash character
(`#`) are treated as comments and ignored unless the comment starts with `#Fields:` and contains
comma-delimited list of column names. In that case, the cmdlet uses those column names. This is the
standard format for Windows IIS and other web server logs. For more information, see [Extended Log
File Format](https://www.w3.org/TR/WD-logfile.html).

## RELATED LINKS

[ConvertTo-Csv](ConvertTo-Csv.md)
Expand Down
34 changes: 33 additions & 1 deletion reference/7.4/Microsoft.PowerShell.Utility/ConvertFrom-Csv.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: Microsoft.PowerShell.Commands.Utility.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Utility
ms.date: 11/29/2022
ms.date: 11/18/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/convertfrom-csv?view=powershell-7.4&WT.mc_id=ps-gethelp
schema: 2.0.0
title: ConvertFrom-Csv
Expand Down Expand Up @@ -147,6 +147,32 @@ When the **UseCulture** parameter is used, be sure that the current culture's de
separator matches the delimiter used in the CSV strings. Otherwise, `ConvertFrom-Csv` can't
generate objects from the CSV strings.

### Example 5: Convert CSV data in W3C Extended Log Format

This example shows how to convert CSV data in W3C Extended Log Format to objects.

```powershell
$logData = @"
#Version: 1.0
#Date: 12-Jan-1996 00:00:00
#Fields: time,cs-method,cs-uri
00:34:23,GET,/foo/bar.html
12:21:16,GET,/foo/bar.html
12:45:52,GET,/foo/bar.html
12:57:34,GET,/foo/bar.html
"@
ConvertFrom-Csv $logData
```

```Output
time cs-method cs-uri
---- --------- ------
00:34:23 GET /foo/bar.html
12:21:16 GET /foo/bar.html
12:45:52 GET /foo/bar.html
12:57:34 GET /foo/bar.html
```

## PARAMETERS

### -Delimiter
Expand Down Expand Up @@ -257,6 +283,12 @@ In CSV format, each object is represented by a character-separated list of the p
the object. The property values are converted to strings, using the `ToString()` method of the
object. There is no way to export the methods of the object.

`ConvertFrom-Csv` also supports the W3C Extended Log format. Lines starting with the hash character
(`#`) are treated as comments and ignored unless the comment starts with `#Fields:` and contains
comma-delimited list of column names. In that case, the cmdlet uses those column names. This is the
standard format for Windows IIS and other web server logs. For more information, see [Extended Log
File Format](https://www.w3.org/TR/WD-logfile.html).

## RELATED LINKS

[ConvertTo-Csv](ConvertTo-Csv.md)
Expand Down
37 changes: 34 additions & 3 deletions reference/7.5/Microsoft.PowerShell.Utility/ConvertFrom-Csv.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: Microsoft.PowerShell.Commands.Utility.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Utility
ms.date: 11/29/2022
ms.date: 11/18/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/convertfrom-csv?view=powershell-7.5&WT.mc_id=ps-gethelp
schema: 2.0.0
title: ConvertFrom-Csv
Expand All @@ -25,8 +25,7 @@ ConvertFrom-Csv [[-Delimiter] <Char>] [-InputObject] <PSObject[]> [-Header <Stri
### UseCulture

```
ConvertFrom-Csv -UseCulture [-InputObject] <PSObject[]> [-Header <String[]>]
[<CommonParameters>]
ConvertFrom-Csv -UseCulture [-InputObject] <PSObject[]> [-Header <String[]>] [<CommonParameters>]
```

## DESCRIPTION
Expand Down Expand Up @@ -148,6 +147,32 @@ When the **UseCulture** parameter is used, be sure that the current culture's de
separator matches the delimiter used in the CSV strings. Otherwise, `ConvertFrom-Csv` can't
generate objects from the CSV strings.

### Example 5: Convert CSV data in W3C Extended Log Format

This example shows how to convert CSV data in W3C Extended Log Format to objects.

```powershell
$logData = @"
#Version: 1.0
#Date: 12-Jan-1996 00:00:00
#Fields: time,cs-method,cs-uri
00:34:23,GET,/foo/bar.html
12:21:16,GET,/foo/bar.html
12:45:52,GET,/foo/bar.html
12:57:34,GET,/foo/bar.html
"@
ConvertFrom-Csv $logData
```

```Output
time cs-method cs-uri
---- --------- ------
00:34:23 GET /foo/bar.html
12:21:16 GET /foo/bar.html
12:45:52 GET /foo/bar.html
12:57:34 GET /foo/bar.html
```

## PARAMETERS

### -Delimiter
Expand Down Expand Up @@ -258,6 +283,12 @@ In CSV format, each object is represented by a character-separated list of the p
the object. The property values are converted to strings, using the `ToString()` method of the
object. There is no way to export the methods of the object.

`ConvertFrom-Csv` also supports the W3C Extended Log format. Lines starting with the hash character
(`#`) are treated as comments and ignored unless the comment starts with `#Fields:` and contains
comma-delimited list of column names. In that case, the cmdlet uses those column names. This is the
standard format for Windows IIS and other web server logs. For more information, see [Extended Log
File Format](https://www.w3.org/TR/WD-logfile.html).

## RELATED LINKS

[ConvertTo-Csv](ConvertTo-Csv.md)
Expand Down
34 changes: 33 additions & 1 deletion reference/7.6/Microsoft.PowerShell.Utility/ConvertFrom-Csv.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: Microsoft.PowerShell.Commands.Utility.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Utility
ms.date: 11/29/2022
ms.date: 11/18/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/convertfrom-csv?view=powershell-7.6&WT.mc_id=ps-gethelp
schema: 2.0.0
title: ConvertFrom-Csv
Expand Down Expand Up @@ -147,6 +147,32 @@ When the **UseCulture** parameter is used, be sure that the current culture's de
separator matches the delimiter used in the CSV strings. Otherwise, `ConvertFrom-Csv` can't
generate objects from the CSV strings.

### Example 5: Convert CSV data in W3C Extended Log Format

This example shows how to convert CSV data in W3C Extended Log Format to objects.

```powershell
$logData = @"
#Version: 1.0
#Date: 12-Jan-1996 00:00:00
#Fields: time,cs-method,cs-uri
00:34:23,GET,/foo/bar.html
12:21:16,GET,/foo/bar.html
12:45:52,GET,/foo/bar.html
12:57:34,GET,/foo/bar.html
"@
ConvertFrom-Csv $logData
```

```Output
time cs-method cs-uri
---- --------- ------
00:34:23 GET /foo/bar.html
12:21:16 GET /foo/bar.html
12:45:52 GET /foo/bar.html
12:57:34 GET /foo/bar.html
```

## PARAMETERS

### -Delimiter
Expand Down Expand Up @@ -257,6 +283,12 @@ In CSV format, each object is represented by a character-separated list of the p
the object. The property values are converted to strings, using the `ToString()` method of the
object. There is no way to export the methods of the object.

`ConvertFrom-Csv` also supports the W3C Extended Log format. Lines starting with the hash character
(`#`) are treated as comments and ignored unless the comment starts with `#Fields:` and contains
comma-delimited list of column names. In that case, the cmdlet uses those column names. This is the
standard format for Windows IIS and other web server logs. For more information, see [Extended Log
File Format](https://www.w3.org/TR/WD-logfile.html).

## RELATED LINKS

[ConvertTo-Csv](ConvertTo-Csv.md)
Expand Down
2 changes: 1 addition & 1 deletion reference/module/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.manager: sewhee
ms.product: powershell
ms.topic: landing-page
quickFilterColumn1: powershell-7.4,windowsserver2025-ps
quickFilterColumn2: azps-14.6.0,sqlserver-ps
quickFilterColumn2: azps-15.0.0,sqlserver-ps
quickFilterColumn3: graph-powershell-1.0,systemcenter-ps-2022
title: PowerShell Module Browser
---
Expand Down