Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How can I add or append additional output to the pipeline in addition to what is already coming in?

14 views
Skip to first unread message

F Morrison

unread,
May 22, 2016, 9:29:11 AM5/22/16
to
How can I simple add/append ADDITIONAL output to the pipeline without losing/destroying what comes in?

For example, in my attempt to turn NetPrfile.InterfaceAlias into a simpler variable named InterfaceAlias, I lose everything else that comes in by the time the information reaches Format-Table:

Get-NetIPConfiguration -Detailed |
Select-Object @{label='InterfaceAlias';expression={$_.NetProfile.InterfaceAlias}} |
Format-Table

I do NOT want to have to create a custom object and have to manually type every property and value that I need to build up that custom object, so please, do NOT waste my time by suggesting that approach.

In an ideal world, I would so something like

Append-ToPipeline $someVariable

which would give me a variable that would have a name of someVariable and a value of whatever is the current value of $someVariable.

Jürgen Exner

unread,
May 22, 2016, 9:47:00 AM5/22/16
to
On Sun, 22 May 2016 06:29:09 -0700 (PDT), F Morrison
<fpmor...@verizon.net> wrote in microsoft.public.windows.powershell:

[Please limit your line length to ~75 characters as has been the tried
and proven custom in Usenet for the past 3 decades. It not only makes
reading easier but also gives many more options to reply at the point to
the point]

You question is unclear.

>How can I simple add/append ADDITIONAL output to the pipeline without losing/destroying what comes in?

Here you are asking about how to add new elements to a pipeline

>For example, in my attempt to turn NetPrfile.InterfaceAlias into a simpler variable named InterfaceAlias, I lose everything else that comes in by the time the information reaches Format-Table:

And here (in the first part of that never-ending line) you seem to be
asking about how to modify the existing elements in the pipeline.

So, which one is it?

jue
0 new messages