ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Lindwall <JLindw...@Xifin.com>
Subject RE: SQL target commits code as single line in oracle
Date Thu, 27 Feb 2003 20:18:12 GMT
I'm trying your PLSQLLoad task for triggers in Oracle 8i and it does retain the formatting
which is nice.  What I also need is to be able to support multiple CREATE statements in a
single file, like this:

CREATE OR REPLACE TRIGGER TRIGGER1
  -- trigger1 code here
END;
/
CREATE OR REPLACE TRIGGER TRIGGER2
  -- trigger2 code here
END;

Using PLSQLLoad, this results in a single (uncompilable) trigger that consists of the source
for both triggers in the file combined into one trigger.  I had hoped it would create tw otrigers:
TRIGGER1 and TRIGGER2.  If I run this same script in a GUI tool we use called TOAD it works
as expected.

My target in build.xml looks like this:

        <plsql userid="${db.user}" password="${db.password}" driver="${db.driver}" url="${db.url}"
classpath="${db.classpath}" delimitertype="row"  delimiter="/" print="yes">
            <transaction src="${build.database.dir}/auditing/createTriggers.sql"/>
        </plsql>

Thanks for any help.

John

-----Original Message-----
From: Anderson, Rob H - VSCM [mailto:Anderson.Rob@vectorscm.com]
Sent: Monday, January 13, 2003 11:59 AM
To: 'Ant Users List'
Subject: RE: SQL target commits code as single line in oracle


I have created a PLSQLLoad task (modified the SQLExec.java) to address this
issue. Give it a try. It seems to work well for me.

-Robert Anderson

-----Original Message-----
From: Michael.Medwith@flagstar.com [mailto:Michael.Medwith@flagstar.com]
Sent: Monday, January 13, 2003 11:22 AM
To: ant-user@jakarta.apache.org
Subject: SQL target commits code as single line in oracle



Does anyone know how to get the sql tag to create objects in Oracle with
multiple lines?  The target seems to read in entire files ignoring the line
breaks.

I am running ant on Unix against Oracle 8, when I run the targets and use
toad or sqlplus to view the objects they are on one line.



Michael Medwith
Flagstar Bank
Wholesale Web Development Team
284-312-5959
michael.medwith@flagstar.com



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:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message