I see you have onerror set to stop. What happens if you don't set that
attribute? It defaults to abort if not set...
On Sun, 15 Nov 2009, Richard Brunelle wrote:
Yes, both echo statements get executed.
Thanks Scot.
On Sun, Nov 15, 2009 at 9:49 PM, Scot P. Floess <sflo...@nc.rr.com> wrote:
Question for you...Do both echo statements get executed? Meaning, both
targets in the depends are honored (printUsStatesData -and"
printAccountsData's echo statements are executed)...
On Fri, 13 Nov 2009, Richard Brunelle wrote:
This is driving me crazy....
I have the following code in an ant file.
<target name="printAccountsData">
<echo message="PRINT accounts DATA USING: ${db.driver} ${db.url}"/>
<sql driver="${db.driver}"
url="${db.url}"
userid="${db.user}"
password="${db.pw}"
onerror="stop"
print="true">
<classpath refid="master-classpath"/>
SELECT * FROM accounts;
</sql>
</target>
<target name="printUsStatesData">
<echo message="PRINT us_states DATA USING: ${db.driver} ${db.url}"/>
<sql driver="${db.driver}"
url="${db.url}"
userid="${db.user}"
password="${db.pw}"
onerror="stop"
print="true">
<classpath refid="master-classpath"/>
SELECT * FROM us_states;
</sql>
</target>
individidualy, each of these targets return proper data from the database.
But when I do this and execute 'ant printData', only results from the
first
dependency listed below prints data. Any insight into why this is
happening? It is as if the second print="true" is being ignored. No
errors
are generated.
<target name="printData" depends="printUsStatesData,
printAccountsData">
<echo message="PRINT DATA USING: ${db.driver} ${db.url}"/>
</target>
Thanks for any insight into this issue.
Richard P. Brunelle
Solutions Architect
BinaryDream
Scot P. Floess
27 Lake Royale
Louisburg, NC 27549
252-478-8087 (Home)
919-890-8117 (Work)
Chief Architect JPlate http://sourceforge.net/projects/jplate
Chief Architect JavaPIM http://sourceforge.net/projects/javapim
Architect Keros http://sourceforge.net/projects/keros
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org
--
Richard Brunelle
~~^^~~
Sent from Atlanta, GA, United States
Scot P. Floess
27 Lake Royale
Louisburg, NC 27549
252-478-8087 (Home)
919-890-8117 (Work)
Chief Architect JPlate http://sourceforge.net/projects/jplate
Chief Architect JavaPIM http://sourceforge.net/projects/javapim
Architect Keros http://sourceforge.net/projects/keros
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org