ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tony Obermeit <ton...@compuserve.com>
Subject RE: creating pl/sql package in sql task, only part of package lo aded
Date Tue, 11 Feb 2003 21:21:42 GMT
Robert,

Your PLSQL task resolved my issues.

I was able to create a pl/sql package using your task in three separate 
ways that the sql task failed on.  The package body is about 750 lines, 
just over 20kb of code.  I created it from a file using the transaction 
task.  I created it with the code in line within the plsql task and I 
created it with wrapped pl/sql code in line within the plsql task. 
(wrapping is an oracle mechanism that allows you to distribute your pl/sql 
code without revealing the source code).

Many thanks for your contribution!  I'll certainly be voting for it to be 
an enhancement request.  I hope others do as well, without this 
enhancement, the limitations of the sql task in an Oracle environment are 
significant.

cheers

Tony

At 12:31 PM 10/02/2003 -0800, Anderson, Rob  H - VSCM wrote:
>
>Attached is the loadplsql task that I created by modifying the sql task. I
>entered this in bugzilla as an enhancement request (Bug# 16945). If you
>think this is worthy please go vote for it. Thanks,
>
>-Robert Anderson
>
>-----Original Message-----
>From: Tony Obermeit [mailto:tonyob@compuserve.com]
>Sent: Monday, February 10, 2003 11:27 AM
>To: Ant Users List
>Subject: Re: creating pl/sql package in sql task, only part of package
>loaded
>
>
>I've tried the other two suggestions, creating the package
>specification/header with it's own sql task and creating the package body
>with it's own sql task.  I also tried the suggestion of loading the pl/sql
>from a file and in both cases the same problem ocurred.  I've run out of
>ideas on using the sql task.  Does anyone know where I can download this
>extended task?  Or have any other ideas of how to get pl/sql loading within
>ant.  The pl/sql code loads fine using sql *plus.
>
>thanks
>
>Tony
>
>At 07:59 AM 10/02/2003 -0500, you wrote:
> >
> >
> >
> >There is an extended task out there that I use to do pl/sql from files.
> >Ant's sql task never liked pl/sql because it treats the statment as a
> >single line statement regardless of the line feeds.
> >
> >Michael Medwith
> >Flagstar Bank
> >Wholesale Web Development Team
> >
> >
> >|---------+---------------------------->
> >|         |           Tony Obermeit    |
> >|         |           <ynotob@yahoo.com|
> >|         |           >                |
> >|         |                            |
> >|         |           02/09/2003 06:53 |
> >|         |           PM               |
> >|         |           Please respond to|
> >|         |           "Ant Users List" |
> >|         |                            |
> >|---------+---------------------------->
> >
> >
> >---------------------------------------------------------------------------
>---------------------------------------------------|
> >   |
> >                                                         |
> >   |       To:       Ant Users List <ant-user@jakarta.apache.org>, Martin
> > <webmaster@laconiadatasystems.com>                      |
> >   |       cc:
> >                                                         |
> >   |       Subject:  Re: creating pl/sql package in sql task, only part of
> > package  loaded                                        |
> >
> >
> >---------------------------------------------------------------------------
>---------------------------------------------------|
> >
> >
> >
> >
> >I don't understand what you are asking in your
> >question about which DTD I'm using.  I haven't
> >specified a dtd in my build.xml document.  My
> >build.xml only has a project element in addition to
> >the target and sql elements.  I've never specified a
> >DTD when using ant scripts.  Please clarify?
> >
> >I can use the src=packagecreate.sql if absolutely
> >necessary but I'd really prefer not to.  I currently
> >deploy an application using ant as the tool to create
> >all my oracle database objects.  I want to keep this
> >script as simple as possible.  At the moment I am
> >deploying my application as a single jar file and it
> >has to have a single build.xml distributed with it.
> >If I could, I would also bundle my build.xml within
> >the jar file but I've separately confirmed that this
> >isn't possible at the moment with ant.
> >
> >Thanks for your reply,
> >
> >Tony
> >
> >--- Martin <mgainty@hotmail.com> wrote:
> > >
> > > Tony-
> > > 1)which DTD are you using?
> > > 2)Could you use src=packagecreate.sql (place your
> > > create package statements
> > > into the sql?)
> > > Thanks,
> > > Martin
> > >
> > > ----- Original Message -----
> > > From: "Antoine Levy-Lambert"
> > > <levylambert@tiscali-dsl.de>
> > > To: "Ant Users List" <ant-user@jakarta.apache.org>;
> > > <tonyob@compuserve.com>
> > > Sent: Sunday, February 09, 2003 7:15 PM
> > > Subject: Re: creating pl/sql package in sql task,
> > > only part of package
> > > loaded
> > >
> > >
> > > > I mean cut your PL/SQL script in two pieces, and
> > > invoke the ant sql task
> > > > twice :
> > > >     - once for the package header,
> > > >     - once for the package body
> > > > Do you have to inline your PL/SQL in your ant
> > > build file, or can you also
> > > > use separate files containing the SQL ?
> > > > If yes, you should separate your build file from
> > > your SQL, it would make
> > > > things maybe clearer.
> > > > Antoine
> > > > ----- Original Message -----
> > > > From: "Tony Obermeit" <ynotob@yahoo.com>
> > > > To: "Ant Users List" <ant-user@jakarta.apache.org>
> > > > Sent: Sunday, February 09, 2003 11:57 PM
> > > > Subject: Re: creating pl/sql package in sql task,
> > > only part of package
> > > > loaded
> > > >
> > > >
> > > > > I believe that is what I'm doing.  Can you
> > > clarify
> > > > > further?
> > > > >
> > > > > In the snippet below, the "create package"
> > > creates the
> > > > > package specification, the "create package body"
> > > > > creates the rest of the package.  I would see
> > > the
> > > > > specification as the same as the "header" you
> > > referred
> > > > > to.  Is that the same thing?
> > > > >
> > > > > Tony
> > > > >
> > > > > > create package
> > > > > >
> > > > > > ..... (specification)
> > > > > >
> > > > > > end;
> > > > > > /
> > > > > >
> > > > > > create package body.....
> > > > > > 742 lines of code in here, 26kb of text
> > > > > >
> > > > > > /
> > > > > >
> > > > >
> > > > > --- Antoine Levy-Lambert
> > > <levylambert@tiscali-dsl.de>
> > > > > wrote:
> > > > > >
> > > > > > You might want to try to do first the package
> > > header
> > > > > > creation, then the
> > > > > > package body
> > > > > > Antoine
> > > > > > ----- Original Message -----
> > > > > > From: "Tony Obermeit" <tonyob@compuserve.com>
> > > > > > To: <ant-user@jakarta.apache.org>
> > > > > > Sent: Sunday, February 09, 2003 10:04 PM
> > > > > > Subject: creating pl/sql package in sql task,
> > > only
> > > > > > part of package loaded
> > > > > >
> > > > > >
> > > > > > > Below is a code snippet I use to create a
> > > pl/sql
> > > > > > package with ant 1.5.1.
> > > > > > >
> > > > > > > The package specification creates
> > > successfully,
> > > > > > the package body does not
> > > > > > > create, it appears that significant lines of
> > > the
> > > > > > code are not saved, with
> > > > > > > only lines at the start and end of the code
> > > being
> > > > > > created.  The code is
> > > > > > 742
> > > > > > > lines which about 26kb of text.  It almost
> > > seems
> > > > > > like the sax parsing of
> > > > > > > the sql text doesn't correctly pick up the
> > > middle
> > > > > > text.
> > > > > > >
> > > > > > > Is there a limit to how much pl/sql text can
> > > go in
> > > > > > to the sql task?  Am I
> > > > > > > running the pl/sql creation the way I
> > > should?  Any
> > > > > > other ideas?
> > > > > > >
> > > > > > > thanks
> > > > > > >
> > > > > > > Tony
> > > > > > >
> > > > > > > <target name  = "create" >
> > > > > > >
> > > > > > > <sql
> > > > > > >              driver  =
> > > > > > "oracle.jdbc.driver.OracleDriver"
> > > > > > >              url = "${database.jdbc.url}"
> > > > > > >              userid = "${database.user}"
> > > > > > >              password =
> > > "${database.password}"
> > > > > > >              print = "true"
> > > > > > >              delimiter = "/"
> > > > > > >              onerror   = "abort" >
> > > > > > >
> > > > > > > <![CDATA[
> > > > > > >
> > > > > > > create package
> > > > > > >
> > > > > > > ..... (specification)
> > > > > > >
> > > > > > > end;
> > > > > > > /
> > > > > > >
> > > > > > > create package body.....
> > > > > > > 742 lines of code in here, 26kb of text
> > > > > > >
> > > > > > > /
> > > > > > >
> > > > > > > ]]>
> > > > > > >
> > > > > > > </sql>
> > > > > > > </target>
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > >
> >---------------------------------------------------------------------
> > > > > > > To unsubscribe, e-mail:
> > > > > > ant-user-unsubscribe@jakarta.apache.org
> > > > > > > For additional commands, e-mail:
> > > > > > ant-user-help@jakarta.apache.org
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > >
> >---------------------------------------------------------------------
> > > > > > To unsubscribe, e-mail:
> > > > > > ant-user-unsubscribe@jakarta.apache.org
> > > > > > For additional commands, e-mail:
> > > > > > ant-user-help@jakarta.apache.org
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > __________________________________________________
> > > > > Do you Yahoo!?
> > > > > Yahoo! Mail Plus - Powerful. Affordable. Sign up
> > > now.
> > > > > http://mailplus.yahoo.com
> > > > >
> > > > >
> > >
> >---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail:
> > > ant-user-unsubscribe@jakarta.apache.org
> > > > > For additional commands, e-mail:
> > > ant-user-help@jakarta.apache.org
> > > > >
> > > >
> > > >
> > > >
> > >
> >---------------------------------------------------------------------
> > > > To unsubscribe, e-mail:
> > > ant-user-unsubscribe@jakarta.apache.org
> > > > For additional commands, e-mail:
> > > ant-user-help@jakarta.apache.org
> > > >
> > >
> > >
> >---------------------------------------------------------------------
> > >
> >=== message truncated ===
> >
> >
> >__________________________________________________
> >Do you Yahoo!?
> >Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
> >http://mailplus.yahoo.com
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: ant-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: ant-user-help@jakarta.apache.org
> >
> >
> >
> >
> >
> >
> >
> >This e-mail may contain data that is confidential, proprietary or
>"non-public
> >personal information", as that term is defined in the Gramm-Leach-Bliley
>Act
> >(collectively, "Confidential Information"). The Confidential Information is
> >disclosed conditioned upon your agreement that you will treat it
> >confidentially and in accordance with applicable law, ensure that such data
> >isn't used or disclosed except for the limited purpose for which it's being
> >provided and will notify and cooperate with us regarding any requested or
> >unauthorized disclosure or use of any Confidential Information. By
>accepting
> >and reviewing the Confidential Information you agree to indemnify us
>against
> >any losses or expenses, including attorney's fees that we may incur as a
> >result of any unauthorized use or disclosure of this data due to your acts
>or
> >omissions. If a party other than the intended recipient receives this
>e-mail,
> >you are requested to instantly notify us of the erroneous delivery and
>return
> >to us all data so delivered.
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> >For additional commands, e-mail: user-help@ant.apache.org
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>For additional commands, e-mail: user-help@ant.apache.org
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>For additional commands, e-mail: user-help@ant.apache.org




Mime
View raw message