Help with Export-CSV commandlet

Hello, I have a basic powershell command that I want to execute and export the data to a CSV file.  If I execute the command and have the output go to a .txt file (using Out-File c:\output.txt) the command works perfectly. But when I use the Export-CSV
c:\output.csv all I get is the following:
#TYPE Microsoft.PowerShell.Commands.Internal.Format.FormatStartData
"ClassId2e4f51ef21dd47e99d3c952918aff9cd","pageHeaderEntry","pageFooterEntry","autosizeInfo","shapeInfo","groupingEntry"
"033ecb2bc07a4d43b5ef94ed5a35d280",,,,"Microsoft.PowerShell.Commands.Internal.Format.TableHeaderInfo",
"9e210fe47d09416682b841769c78b8a3",,,,,
"27c87ef9bbda4f709f6b4002fa4af63c",,,,,
"27c87ef9bbda4f709f6b4002fa4af63c",,,,,
"27c87ef9bbda4f709f6b4002fa4af63c",,,,,
"27c87ef9bbda4f709f6b4002fa4af63c",,,,,
"27c87ef9bbda4f709f6b4002fa4af63c",,,,,
"4ec4f0187cb04f4cb6973460dfe252df",,,,,
"cf522b78d86c486691226b40aa69e95c",,,,,
The command I am attempting to use is:
Get-ADUser –Filter * -SearchBase “OU=OU3,OU=OU2,OU=Departments,OU=OU1,DC=gf,DC=local” | FT Name,SamAccountName | Export-CSV c:\DETfac.csv
The command also works if I don't specify the fields that I need exported.  As soon as I add the name and samAccountname, I get the output above.  Any assistance would be greatly appreciated

Hi,
Replace FT with Select and you should be fine. You may want to add in -NoTypeInformation to Export-Csv as well.
EDIT: Hah, slow again. =]  See above.
Don't retire TechNet! -
(Don't give up yet - 12,575+ strong and growing)

Similar Messages

  • Help with export-csv append

    I know this has probably been covered a lot but I'm new to powershell and can't get this to work. Here is my simple VMM script.
    #Get list of all Virtual Machines.
    $file = "C:\dev\vmlist.csv"
    $VMHosts = Get-VMHost
    foreach ($VMHost in $VMHosts) {
    Get-VM -VMHost $VMHost | Select-Object Name,Status,Description,HostName | Export-Csv $file -NoTypeInformation
    I'm getting stuck with the export-csv part. I can't figure out how to get it to append to the csv. Can anyone help?
    Thanks.

    I agreee in the answer from big teddy :)
    In PowerShell 3.0 an -Append parameter have been added to export-csv, but it is non existing in 1.0 and 2.0
    Best Regards
    Jakob Gottlieb Svendsen
    Trainer/Consultant - Coretech A/S -
    Blog
    MCT - MCTS - VB.NET - C#.NET - Powershell - VBScript Mastering System Center Orchestrator 2012 - 3 day workshop - worldwide training click
    here

  • Help with exporting and image size or boundaries?

    I am trying to slide the cat into the scene a little at a time foir an animation project I am working on. However, when I export the image the back ground of the image expands with a checkered back ground( showing here in white) and shows the whole cat.
    How do I just show a little of the cat on the image at a time when exporting. I am trying to give the impression that the cat is walking into the room. I do not want to have to cut the cat up.
    I would be thankful for any suggestions.

    Provide the name of the program you are using so a Moderator may move this message to the correct program forum
    This Cloud forum is not about help with program problems... a program would be Photoshop or Lighroom or Muse or ???

  • Help with exporting Deski to text file via Web Intelligence

    We are currently converting from BO version 5 to BO XI rev2. I have a report that must be scheduled to a flie in plain text format. I am using a deski report. When I save as to text, the file is fine. When I schedule it in webi, the file seems to be missing the end of line character for each row in the table, so it cannot be used for an import to another program. Can anybody help with this?-

    well, in that case you need to determine if this issue only happens with a perticular report or all of them, if it happens only with reports imported from 5.x or with newly created reports as well.
    Looks like it is happening only when report is exported from Infoview, not in the Deski client. This might indicate a problem at the Web Apllication server (tomcat or one you use).
    If this issue is happening with any report - it might be a bug. In that case you have no options as there are no more patches for XIR2.
    On the other hand - if all you need is to extract data for consumption in another tool , why not use Data integrator instead ?
    Also, if this desn't work in Deski - does it work if you convert your reports to webi and export from those ?

  • Need help with Export workflow.

    Hello again.
    Today I was experimenting with exporting a project using Export QT Movie and QT Conversion.
    My goal is to show a QT project on the web, either 640x480 or 320xx240, depending on how monstrous the file size is.
    My initial impression was that export QT Movie simply generates (I'm guessing) a full size rendering of the project. It's icon is a FC icon. What I did then was an "Open with..." quicktime(pro). This is where I get confused: I know that the next steps are for for preparing the project for sizes, compressions and so on. The export to QT movie seems to be a longer route to get to the settings that you need to use in QT Conversion, which after selecting QT conversion, you have the Format, Use, and Options settings.
    Am I right so far?
    Some background about my project- Easy setup= DV-NTSC. If I look in my browser, my clips are 720x480, 29.97fps, Compressor(?)DV/DVCPRO-NTSC, pixel aspect ratio, NTSC-CCIR 601 and anamorphic is checked.
    I also have still photos motion control stuff, PS tiffs, that do not have anamorphic checked.
    Form here on is where I get confused.
    Under settings, I am selecting DV/dvc-NTSC for compression frame rate 29.97, medium compressor, scan mode, interlaced, and aspect 4:3.
    The filters setting I don't use.
    The size setting I'm trying 320x240 with aspect ratio and de interlace video UNCHECKED.
    Is this a good workflow for the web. I notice on 640x480 my titles (livetype) seem kind of jagged.
    Any help preparing a project for the web would be appreciated. If you need more info let me know.
    Thanks so much.
    Jonathan

    Thanks for the additional comments and ideas.
    In terms of profile, as I mentioned, the intermediates will be going off to the editor (off-site) for editing on his FCP suite.  I'll stick to working in the prescribed HDTV (Rec. 709) space, and I've given him all the detail I can of how I'm working, but crucially I haven't stood at his edit-suite to see how the stuff looks.
    But, he's no newbie, so I'm hoping it'll be OK.
    Blasted shame about the H.264 BluRay not being compatible with QT - I thought I had this whole issue beat until that came along.  It's not a matter of disk space here, but the editor is mithering that the intermediates we are testing, in either PNG, or Animation, and a couple of others, are choking his playback.
    I'm not sure what to say about that, other than to go down this road of trying to squish these intermediates as low as possible without wrecking the look, hence finding that the DNxHD is providing the best solution.  If it had been a SD project, I might well have tried the native H.264, even over our normal PNG workflow.
    So what will play the native H.264 BluRay compressed output?
    Julian.

  • Help with export with query option

    I need help with an export with query option.
    I have a script that includes the following
    auddate=`date '+20%y%m%d'`
    file="cal_shrlgpa"$auddate".dmp"
    exp / file=$file tables=shrlgpa query\=" where shrlgpa_pidm in (Select sztahbr_pidm from purdue.sztahbr where sztahbr_to_extract\=\'Y\' and sztahbr_export_status\=\'N\')\"
    echo 'cal export file created:'$file
    when I run the script, I get the following error:
    cal_export_tables.sh[7]: 0403-057 Syntax error at line 7 : `"' is not matched.
    Can somone help me with the query option?

    I made the suggested change:
    exp / file=$file tables=shrlgpa query=" where shrlgpa_pidm in (Select sztahbr_pidm from purdue.sztahbr where sztahbr_to_extract=\'Y\' and sztahbr_export_status=\'N\')"
    and got the following error:
    LRM-00116: syntax error at 'sztahbr_to_extra' following 'where'
    EXP-00019: failed to process parameters, type 'EXP HELP=Y' for help
    Shannon

  • Working with Export-CSV and add-member

    Hello, I am working on a powershell script that allows for a list of IP addresses to be stored in a file. This file is then imported into the powershell script. Then while these IP addresses are there, there are certain things that i am wanting to retrieve
    from each IP address such as Operating System Type. 
    My code is as follows so far:
    # Checks the file IPAddresses.txt for a list of IpAddresses to run against.
    #$computerlist= Get-Content c:\IpAddresses.txt
    #declare an array to cllect our results objects
    $resultsarry = @()
    $computer = $ComputerListA
    # checks each item inside of the IpAddresses.txt file.
    Foreach ($IpAddress in (Get-Content c:\IpAddresses.txt))
    # Gets the IpAddress of the Computer that we are checking against.
    $IpAddress = Get-WmiObject Win32_NetworkAdapterConfiguration -ComputerName $IpAddress | Select-Object IpAddress
    # Gets the Type of operating system from the computer we are checking against.
    $OperatingSystemType = Get-WmiObject Win32_OperatingSystem -ComputerName $IpAddress | Select-Object Caption
    #Writes to the host the output received in previous commands.
    write-host "IpAddress is $computerlist"
    write-host "Operating System = $OperatingSystemType"
    # Creates a new custom object to hold our result.
    $OutputObj = new-object PSObject
    $OutputObj| add-member -membertype NoteProperty -name "IpAddress" -Value $IpAddress
    $OutputObj| add-member -membertype NoteProperty -name "Operating System" -Value $OperatingSystemType
    # Adds our new Object into the array.
    $resultsarray += $OutputObj
    # exports the results of the script to this csv file below.
    $resultsarray | Format-Table -AutoSize
    $resultsarray | Export-Csv -NoTypeInformation -Path C:\OperatingSystems.csv
    write-host "Script complete reached end of file and out of IP Addresses to search against."
    write host "Results were sent to C:\OperatingSystems.csv"
    When running the code I am receiving the follow errors:
    IpAddress is
    Operating System =
    Method invocation failed because [System.Management.Automation.PSObject] doesn't contain a method named 'op_Addition'.
    At C:\Users\cos04\Desktop\ram.ps1:36 char:5
    + $resultsarray += $OutputObj
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidOperation: (op_Addition:String) [], RuntimeException
    + FullyQualifiedErrorId : MethodNotFound

    Looks like a simple typo.
    $resultsarry = @()
    should be
    $resultsarray = @()
    [string](0..33|%{[char][int](46+("686552495351636652556262185355647068516270555358646562655775 0645570").substring(($_*2),2))})-replace " "

  • Help with exporting data from pdf form

    I have about 100 pdf forms that I created in adobe forms central and distributed as a pdf form (rather than on the web). I am trying to export the data into a spreadsheet but when I export it, the fields are all jumbled in the csv file, as in they are not in the same order. I need to export the data all together so I'm going to the forms menu and selecting "manage form data" and then selecting "merge data files into spreadsheet". I tried exporting a single file but that gave me something really weird.
    Please help, I have a deadline next week to analyze this data and can't make sense of it once it is exported to a spreadsheet.

    Would you please share your form with me and send me one of your pdf forms and some of the csv files?
    You can share your form by doing the following:
    1. Click on the “Share” icon on the bottom left corner.
    2. Click on “Add Collaborator” on the popup menu.
    3. Enter [email protected] under “People to share with”.
    4. Set subject to "Export data from pdf form"
    5. Click the “Share” button on the bottom right of the dialog.
    Thanks
    Ken

  • Help with exporting Minecraft video

    Hello. My name is Reynir Aron. I make Minecraft videos and I recently switched from Final Cut Pro 7 to Premiere Pro CS6 and I love using Premiere.
    However there is one little problem, when I export the video (even if I do it through Media Encoder) the video looks very smoothed out (for example the text looks really crappy and isn't pixellated).
    Can anybody help me? The video is not being scaled up, the source video, my sequence and the export settings are all 1280x720.
    By the way, is there any plugin or anything that lets me export using QuickTime Pro 7?
    Here is a screenshot of the output I get:
    This also happens if I check "Use Maximum Render Quality".
    This is what I see in Premiere's Program window:
    I have an iMac8,1 (Early 2008) with a 2,8GHz Intel Core 2 Duo, 4GB 800 MHz DDR2 SDRAM, an ATI Radeon HD 2600 Pro 256 MB and I'm running OS X Mountain Lion 10.8.2.

    I think my daughter is using FRAPS, but of course not transcoding, just putting that right into Premiere. If your captured file is 30fps, what is the transcoded ProRes file? I don't know if ProRes supports non-video settings, so maybe that is converted to 29.97? But then the edit sequence is 30fps, and I do see an issue - FIELDS is set to LOWER, but should be PROGRESSIVE. That could be causing the jaggies issue on your output.
    How did you create the editing Sequence? Try creating a NEW SEQUENCE with the same settings, except make it Progressive, then copy/paste contents of interlaced sequence into the progressive sequence and then Export again, see if that helps. Or just do a short sample to check, to save time.
    Thanks
    Jeff

  • Help with exporting forms based data to Excel 2007

    I have a user who is attempting to export forms based data to Microsoft Excel 2007 and when he attempts this he receives a message stating that Windows does not recognise this file type (tsv). I am not too familiar with Office 2007 so I am unable to direct this users as to how to correct this issue.
    Is someone able to give me the navigation path to help me to assist this user? thanks

    Did you verify the file type from Windows Explorer?
    1) Right click on My Computer > Explore
    2) Go to Tools > Folder Options
    3) Click on File Types tab
    4) Check if TSV file is defined there or not. If it is not there, click on New and add the File Extension

  • Help with exporting tracks from Garageband into iTunes please?!

    I have voice-recorded a list of Italian words and phrases which I want to import into iTunes as separate tracks so that I can shuffle them & test myself to learn them. So far I have been using the cycle region to import each word but it is taking forever! I beieve it is not possible to have multpile cycle regions and have been playing about with the markers using the podcast track but I can't get it to export in chapters either.
    Is there a way to split a single track in Garageband and import it as mulitple tracks into iTunes all at the same time?
    Thanks for any help you can give me!

    vanessa2011 wrote:
    the chapters only work when you actually burn to CD. I assume that's correct?
    for your purposes, yes (technically it would create podcast style chapters so you could jump past a section, for instance, but not in a shuffle fashion like you want)
    vanessa2011 wrote:
    I'm guessing that will take an awful lot of CDs?!
    you could use a re-writtable, but no, this doesn't sound like a really workable solution for what you're doing.
    vanessa2011 wrote:
    Just two of the chapters has already become 220 'songs' in iTunes and over 20MB.
    one thing you should be doing is selecting the "compress" option in the export dialogue. you can probably use very aggressive compression for spoken word since hi-fidelity wouldn't be that important (you might experiment with a custom setting to see how low you can go with it still being acceptable)
    vanessa2011 wrote:
    I wonder how much would fit onto a CD
    in terms of audio, it's time, not disc space. a standard CD holds 74 minutes of audio (some store 80)
    you could try an audio editor instead of GB:
    http://www.bulletsandbones.com/GB/GBFAQ.html#audioeditors
    (Let the page FULLY load. The link to your answer is at the top of your screen)
    but GB is probably the most simple option

  • Help With Exporting

    Hey I just created a slideshow, with music, from itunes. When i try to export it into iDVD it says there is an error. The music is purchased so if that is an issue it can be fixed with ease. Thanks any help would be great.

    Welcome to the Apple Discussions. What version of Quicktime are you using? If it isn't 7.1.3 then update to it. That may be the problem. You can open the Console and look at the logs for iPhoto to see if there's an entry that will identify the issue.
    Do you Twango?
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've written an Automator workflow application (requires Tiger), iPhoto dB file backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.

  • Help with exporting to pdf

    If someone could help me with this I would greatly appreciate it!!
    Using Indesgin CS3: I am trying to export page by page of an indesign document....there are 16 pages and when I get to page 8, it tells me that it is an invalid page name.....? Any ideas?

    You're probably using sections. Is there a little triangle over page 8 in the Pages palette? That means a section starts there. Select the page and go to Numbering and Section Options in the Pages palette menu. Remove the prefix.
    You can also export using absolute page numbers if you use a + (plus) in front of the page. If your book's pages are numbered: i, ii, iii, 1, 2, 3 you could export as pages +1 - +6.

  • Help with exporting HD for use in DVDSP.

    Hi Guys,
    Very glad I found this forum as I am just out of ideas to get this working. Here is the situation:
    I have a project of a wedding in HDV, which contains 3 sequences with the following lengths:
    The Service = 45mins
    Photoshoot = 5mins
    Reception = 80mins
    I have decided I would like to have the Service + photoshoot on ONE DVD and the reception on ONE DVD. If possible? If not possible I will have the reception spread over two but i do not see the need.
    First of all I have a Powermac dual 1.8 which doesn't have a dual layer dvd burner, so to have a higher quality result and to be able to fit more on I have decided I probably best to get a Dual Layer burner to do this project.
    But before I do that, I need to work out what is the best settings for exporting this project out of FCP 5.1 to work on a SD DVD? Do I use compressor? If so which preset or what settings of my own? I have tried various things and I honestly get lost and my project in DVD SP is around 12GB. So i try exporting again with other ways in compressor and then the quality just looks terrible.
    The FCP project is all in HDV with apple intermediate codec so I would be exporting from that, but obviously only need the DVD in SD!
    If it helps converting the HD project to SD/DV I can do that with the sequence which I did try and then some more export experimenting but it looked really bad.
    Please help guys I am desperate and no idea on what to do here.
    I really appreciate your time, feel free to ask me anything to help you determine what I should do.
    Thank you so much.
    Matt
    G5 Dual 1.8ghz   Mac OS X (10.4.10)   2.5gb ram, 320gb + 160gb + 320gb ext.

    Thanks for the reply.
    How can I set the audio in the DVD SP project?
    I am using the "default" settings now which are 4.0 and 7.0 and it still says too high? Whats the deal
    Here is the log:
    Starting DVD Build HAWKESDVDPROJECT...
    Compiler Initializing...
    Precompiling Project HAWKESDVDPROJECT
    Compiling VMG Information...
    Created 9 PGCs in VTSM1
    Created 5 PGCs in VTSM2
    Created 5 PGCs in VTSM3
    Created 5 PGCs in VTSM4
    Created 5 PGCs in VTSM5
    Created 8 PGCs in VMG.
    1 Menu(s) will be created...
    Compiling Menu PGCs...
    Compiling Menu#1 (Menu 1)...
    Rendering Menu:Menu 1,Language:1...
    Generating Transition: VTSM #01, VOB #1...
    Generating Transition: VTSM #01, VOB #2...
    Writing VIDEO_TS.VOB
    Compiling Menu PGCs...
    Writing VTS020.VOB
    Compiling Menu PGCs...
    Writing VTS030.VOB
    Compiling Menu PGCs...
    Writing VTS040.VOB
    Compiling Menu PGCs...
    Writing VTS050.VOB
    5 VTSs and 5 Titles will be created...
    Compiling VTS#1 (PhotoShoot-uncomp8bit (Video))...
    Muxing VTS011.VOB
    Done.
    Compiling VTS#2 (PhotoShoot-uncomp8bit (Video)-2)...
    Writing VTS020.VOB
    Muxing VTS021.VOB
    Done.
    Compiling VTS#3 (PhotoShoot-uncomp8bit (Video)-3)...
    Writing VTS030.VOB
    Muxing VTS031.VOB
    Done.
    Compiling VTS#4 (Service-uncomp8bit (Video))...
    Writing VTS040.VOB
    Muxing VTS041.VOB
    Video Bitrate Too High
    I'm not sure whats going on with 3 different photoshoots? I am so lost and restarted the project about 4 times now.
    Mode: One Pass?
    Motion Estimation?
    Any suggestions? Sorry to keep bothering you.

  • Help with exporting. Video looks horrible after export, but great when in premiere pro

    Hey guys, looking for some advice on exporting.
    When I finish a video, the color and everything looks great while in premiere pro, but after exporting it, the color ends up looking dull and the whole video looks blurry.  I'm filming with a canon vixia hf200 at 60i. It imports as a AVCHD file, I deinterlace it, and then export at the Vimeo HD settings. What can be causing the video to look horrible after exporting? What settings should I be exporting under? Any help would be appreciated!

    It looks like you're coming up against some of the colorspace handling issues that the Premiere pipeline has.
    Since your source is 60i AVCHD it's HD and thus rec709 colorspace. If it gets encoded with the standard rec601 colorspace (SD sizes are this) then all the colors get crushed. Look for a "709" and "601" radio button in your export settings. If it's not there you're out of luck.
    The "blurry" is probably a poor quality de-interlacer. If Vimeo permits interlaced vs progressive do that instead. it's always cleaner to stay in the same video format all the way through.
    TECHNICAL ASIDE:
    rec709 is a triangle of possible colors that can be expressed by mixing of ratios of 3 emitters (the R G B corners of the triangle). (they are the RGB phosphors of a CRT and now LCD pixel elements)
    rec709 is a bigger triangle than rec601 so it's capable of more colors. but if you accidently map that triangle's corners to the coordinates of rec601 it gets crushed.
    In photography the "sRGB" uses the rec709 triangle. A bigger triangle that that is "Adobe RGB". So if you work in Adobe RGB and export to sRGB without conversion the colors get crushed because sRGB in inside the triangle of "Adobe RGB".
    http://en.wikipedia.org/wiki/Srgb
    http://en.wikipedia.org/wiki/Rec._709
    http://upload.wikimedia.org/wikipedia/commons/8/8f/CIExy1931_sRGB.svg

Maybe you are looking for

  • IPod Touch "already synced with another library", Corrupt Backup?

    I plugged my iPod into the only PC it's ever been plugged into today, and it came up with "This Ipod is already synced with another library" when I tried to sync it. I tried a variety of solutions I found on the internet, but none seemed to work. So,

  • I moved my music to external hard drive and now iphone 4S won't sync

    I recently moved ALL of my media (music, movies, etc) to my external Seagate 1TB hard drive to free up 200+ gig on my Macbook pro. I followed all of the steps, everything works perfectly, iphone is recognized and syncs all playlists, apps, etc EXCEPT

  • Mini Disc stuck and won't eject!

    My friend just stuck one of those mini-disc things into my DVD/CD slot. (You know, those mini versions of a cd)..anyway, I've tried doing what Disc Utility said to but its not working...PLEASE HELP!!

  • Why didn't it back up?

    So I've had my Ipad for a few years.   I've set it up so that it should regularly back up on i Cloud on it's on.   It's attached to a power source (check), it has a wi-fi connection (check), screen is locked (check), settings indicate that the last b

  • Hyperlink in Java platform

    Hi, I hve created parent and child report in parent report i have used Hyperlink after clicking parameter is passing based on that child report is opening.....this linking is possible when i am setting prefrence in Infoview as a Intrective but i am s