By default export to spreadsheet showing owssvr.iqy , we need to have owssvr.csv Please help.
-
SharePoint does not export to CSV, IQY is an Excel query to the SharePoint list. You can do the export to CSV from Excel. There may be some Apps in the Microsoft Store that do a direct export.Danny '365CSI' Engelman– Danny '365CSI' Engelman2015-12-03 15:34:31 +00:00Commented Dec 3, 2015 at 15:34
Add a comment
|
1 Answer
By default SharePoint only support IQY format, In order to export the list into csv you have to use the 3rd party tools or run some kind of script.
$spSiteUrl = "http://sharepointwebapplication"
$listtitle="My Custom List"
$spWeb= Get-SPWeb -Identity $spSiteUrl
Function ImportDataFromListToCSV
{
IF($spWeb -ne $null)
{
$list = $spWeb.Lists.TryGetList($listtitle)
$exportlist = @()
$items = $list.Items
Write-Host "Exporting........" -ForegroundColor Yellow
if($items -ne $null)
{
#Here "givenName" column name for CSV file and "Given Name" column name SharePoint List
$items | %{ select-object -input $_ -prop @{Name='givenName';expression={$_["Given Name"];}},@{Name='surname';expression={$_["Family Name"];}};}| Export-Csv -Path C:\Demo.csv -NoTypeInformation
Write-Host "SharePoint list data is exported successfully." -ForegroundColor Green
$spWeb.Dispose()
}
Else
{Write-Host "No data found in the list "$listtitle -ForegroundColor Yellow}}
}
Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") | out-null
$site = new-object Microsoft.SharePoint.SPSite("http://yoursite")
$web = $site.RootWeb
$list = $web.Lists[$listname]
$view = $list.Views["Current Month"]
$items = $list.GetItems($view)
$items | %{ select-object -input $_ -prop @{Name='Title';expression={$_.Title;}}, @{Name='Check Number';expression={$_["Check Number"];}}; } | Export-Csv -Path c:\test.csv
Export SharePoint List Items to CSV using PowerShell
Read more: