Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

bcp.pipe in windows environment

3 posts in General Discussion Last posting was on 2011-10-04 18:01:17.0Z
tartampion Posted on 2011-10-03 14:06:59.0Z
Sender: 5385.4e89c01b.1804289383@sybase.com
From: tartampion
Newsgroups: sybase.public.ase.general
Subject: bcp.pipe in windows environment
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4e89c183.544e.1681692777@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 3 Oct 2011 07:06:59 -0700
X-Trace: forums-1-dub 1317650819 10.22.241.41 (3 Oct 2011 07:06:59 -0700)
X-Original-Trace: 3 Oct 2011 07:06:59 -0700, 10.22.241.41
Lines: 4
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30566
Article PK: 72739

I am trying to bcp.pipe in a windows environment, and have
not been able to. using bcp.pipe in windows environment, is
it possible? any help in that regard is appreciated.
Tartampion


Rob V Posted on 2011-10-03 19:29:39.0Z
From: Rob V <rob@DO.NOT.SPAM.sypron.nl.REMOVE.THIS.DECOY>
Reply-To: rob@DO.NOT.SPAM.sypron.nl.REMOVE.THIS.DECOY
Organization: Sypron BV
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:7.0.1) Gecko/20110929 Thunderbird/7.0.1
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: bcp.pipe in windows environment
References: <4e89c183.544e.1681692777@sybase.com>
In-Reply-To: <4e89c183.544e.1681692777@sybase.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4e8a0d23$1@forums-1-dub>
Date: 3 Oct 2011 12:29:39 -0700
X-Trace: forums-1-dub 1317670179 10.22.241.152 (3 Oct 2011 12:29:39 -0700)
X-Original-Trace: 3 Oct 2011 12:29:39 -0700, vip152.sybase.com
Lines: 35
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30567
Article PK: 72740


On 03-Oct-2011 16:06, tartampion wrote:
> I am trying to bcp.pipe in a windows environment, and have
> not been able to. using bcp.pipe in windows environment, is
> it possible? any help in that regard is appreciated.
> Tartampion

Assuming that with "bcp.pipe" you mean "running bcp reading from, or
writing to a Unix FIFO (created with mkfifo), also known as a 'pipe'...
On Unix this works. On Windows it may work if you use a shell emulator
like Cygwin. In native WIndows this does not work.
Note that WIndows also has a concept of 'name pipes', but this is
something entirely different.

For more background, check out my blog post at
http://blogs.sybase.com/database/2010/08/is-bcp-supported-with-fifos-yes-finally/


--
HTH,

Rob V.
-----------------------------------------------------------------
Rob Verschoor

Certified Sybase Professional DBA for ASE 15.0/12.5/12.0/11.5/11.0
and Replication Server 15.0.1/12.5 // TeamSybase

Author of Sybase books (order online at www.sypron.nl/shop):
"Tips, Tricks& Recipes for Sybase ASE" (ASE 15 edition)
"The Complete Sybase ASE Quick Reference Guide"
"The Complete Sybase Replication Server Quick Reference Guide"

rob@NO.SPAM.sypron.nl | www.sypron.nl | Twitter: @rob_verschoor
Sypron B.V., The Netherlands | Chamber of Commerce 27138666
-----------------------------------------------------------------


Sherlock, Kevin [TeamSybase] Posted on 2011-10-04 18:01:17.0Z
From: "Sherlock, Kevin [TeamSybase]" <kevin.sherlock@teamsybase.com>
Newsgroups: sybase.public.ase.general
References: <4e89c183.544e.1681692777@sybase.com>
Subject: Re: bcp.pipe in windows environment
Lines: 28
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5512
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5512
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4e8b49ed$1@forums-1-dub>
Date: 4 Oct 2011 11:01:17 -0700
X-Trace: forums-1-dub 1317751277 10.22.241.152 (4 Oct 2011 11:01:17 -0700)
X-Original-Trace: 4 Oct 2011 11:01:17 -0700, vip152.sybase.com
X-Authenticated-User: teamsybase
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30570
Article PK: 72749

If you have Powershell for windows (standard in systems like Windows Server
2008 R2).

PS> [reflection.Assembly]::LoadWithPartialName("system.core")

Or if you are using Powershell v2:

PS> Add-Type -AssemblyName system.core

Then create a pipe named "mypipe"

PS> $pipe = New-Object system.IO.Pipes.NamedPipeServerStream("mypipe")

Then test:

PS> bcp master..sysobjects out mypipe -Smyserver -Umylogin -Pmypassword -c

PS> cat mypipe

<tartampion> wrote in message news:4e89c183.544e.1681692777@sybase.com...
>I am trying to bcp.pipe in a windows environment, and have
> not been able to. using bcp.pipe in windows environment, is
> it possible? any help in that regard is appreciated.
> Tartampion