Hi Folks,
I have a ant sql statement
<target name="insertData">
<sql driver="${jdbcdriver}" url="${dburl}/BillPay"
userid="${userid}" password="${password}"
print="yes" onerror="continue"
output="${tmp.dir}/dbModification.txt">
<transaction> INSERT INTO Payment (RefNumber,
VAN, Amount, OptCode, VendorID,
PriorRefNumber, TransactionTS,
IsProcessed) VALUES
('6569998989','2131213','1131',2031,232,'7898', { fn NOW() },1);
</transaction>
<transaction> INSERT INTO Payment (RefNumber,
VAN, Amount, OptCode, VendorID,
PriorRefNumber, TransactionTS,
IsProcessed) VALUES
('9565689232323','21313213','1131',2031,232,'7898', { fn NOW() },1);
</transaction>
</sql>
Here there are 2 sql statement to insert. But I have more than 100 data
put in txt file.
Like this
'1569998989','2131213','1131',2031,232,'7898', { fn NOW() },
'2569998989','2131213','1131',2031,232,'7898', { fn NOW() },
'3569998989','2131213','1131',2031,232,'7898', { fn NOW() },
Could you tell me How can load these data from a txt file. And using
loop to insert these data into database. Which means dynamically.
So I don't need to put more thant 100 sql statement in the ant build
file.
Thank you very much.
Cwang
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]