From oracle-l-bounce@freelists.org Fri Jul 23 15:33:43 2004 Return-Path: Received: from air189.startdedicated.com (root@localhost) by orafaq.com (8.11.6/8.11.6) with ESMTP id i6NKXST20235 for ; Fri, 23 Jul 2004 15:33:38 -0500 X-ClientAddr: 206.53.239.180 Received: from turing.freelists.org (freelists-180.iquest.net [206.53.239.180]) by air189.startdedicated.com (8.11.6/8.11.6) with ESMTP id i6NKXI620200 for ; Fri, 23 Jul 2004 15:33:28 -0500 Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 8D39272C9AB; Fri, 23 Jul 2004 15:12:16 -0500 (EST) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 06537-54; Fri, 23 Jul 2004 15:12:16 -0500 (EST) Received: from turing (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id D78E972C75E; Fri, 23 Jul 2004 15:12:15 -0500 (EST) Received: with ECARTIS (v1.0.0; list oracle-l); Fri, 23 Jul 2004 15:10:50 -0500 (EST) X-Original-To: oracle-l@freelists.org Delivered-To: oracle-l@freelists.org Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 9363D72C311 for ; Fri, 23 Jul 2004 15:10:49 -0500 (EST) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 06401-48 for ; Fri, 23 Jul 2004 15:10:49 -0500 (EST) Received: from aspen.itsd.gov.bc.ca (aspen.itsd.gov.bc.ca [142.32.11.114]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 19AB372C066 for ; Fri, 23 Jul 2004 15:10:49 -0500 (EST) Received: from pipe.gov.bc.ca (pipe.bcsc.gov.bc.ca [142.32.11.55]) by aspen.itsd.gov.bc.ca (8.12.5-20030917/8.12.5) with ESMTP id i6NKb962025593 for ; Fri, 23 Jul 2004 13:37:10 -0700 Received: by pipe.bcsc.gov.bc.ca with Internet Mail Service (5.5.2657.72) id ; Fri, 23 Jul 2004 13:37:10 -0700 Message-ID: <398EEEA4B3C0B94EACD6263D94EB14FA0602B54D@meadow.gov.bc.ca> From: "Sinats, Toby EBC:EX" To: "'oracle-l@freelists.org'" Subject: RE: Instream SQL in an NT Batch script Date: Fri, 23 Jul 2004 13:37:01 -0700 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2657.72) Content-type: text/plain X-Virus-Scanned: by amavisd-new at freelists.org Content-Transfer-Encoding: 8bit X-archive-position: 5910 X-ecartis-version: Ecartis v1.0.0 Sender: oracle-l-bounce@freelists.org Errors-To: oracle-l-bounce@freelists.org X-original-sender: Toby.Sinats@gems1.gov.bc.ca Precedence: normal Reply-To: oracle-l@freelists.org X-list: oracle-l X-Virus-Scanned: by amavisd-new at freelists.org I believe Microsoft Windows Services for UNIX 3.5 is now free. >From a white paper @ http://www.microsoft.com/windows/sfu/techinfo/overview/sfuwp2.asp " Scripting Windows Services for UNIX 3.5 includes both Korn Shell and C Shell environments, more than 350 UNIX utilities, and Perl 5.6.1 compiled under Interix. These give UNIX developers and administrators the broadest, most familiar, and most compatible scripting environment possible. The utilities include awk, grep, sed, tr, cut, tar, cpio, and a host of others, all of which work as a UNIX user, administrator, or programmer expects. Also included are more than 40 GNU utilities and compilers, including gawk, gcc, g++, and g77." Note, this is not an endorsement, I've never used the (W)SFU (unfortunate acronym that it is), but MS centric colleagues are enthusiastic about it. Toby Sinats -----Original Message----- From: oracle-l-bounce@freelists.org [mailto:oracle-l-bounce@freelists.org] On Behalf Of Branimir Petrovic Sent: Friday, July 23, 2004 1:23 PM To: 'oracle-l@freelists.org' Subject: RE: Instream SQL in an NT Batch script > I am trying to move a couple of Unix scripts to an NT server. I know > just about everything needs to change but the scripts use in > stream SQL > commands and for some reason NT doesn't like the syntax. > > The code is simple just like: > sqlplus / < select something from somewhere; > EOF > > It complains and says < Works on Unix and Linux. > > What am I missing? What you are missing on NT is decent scripting language (and no, VB Script aint it either). Sooner you shake off DOS-batch-ing from your mind, sooner you'll be able to "do stuff" you want or need to do... By default - anything you try to do via DOS batch will be: Ugly: read as "unreadable and hard to maintain" Kludgey: to get DOS batch to do lots of things - you'll have to wrap your mind around insane constructs Unreliable: there are ahem, slight but very gotcha differences between DOS shells across various Win platforms What I'd do if I had lots of "streamed" scripts I'd want to share between Unix and Windows - I'd rewrite 'em all in Python (or Perl if only I knew it;-) and run one and same set of scripts on both "ends", or write small Python (or Perl) parser and stream existing sql stuff into Python/Perl script that will do the job. Branimir ---------------------------------------------------------------- Please see the official ORACLE-L FAQ: http://www.orafaq.com ---------------------------------------------------------------- To unsubscribe send email to: oracle-l-request@freelists.org put 'unsubscribe' in the subject line. -- Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html ----------------------------------------------------------------- ---------------------------------------------------------------- Please see the official ORACLE-L FAQ: http://www.orafaq.com ---------------------------------------------------------------- To unsubscribe send email to: oracle-l-request@freelists.org put 'unsubscribe' in the subject line. -- Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html -----------------------------------------------------------------