minor: always trim away spaces from detail table name so "select * from c_order; c_orderline" work ( note the space after the semicolon separator ).

This commit is contained in:
Heng Sin Low 2013-04-21 20:57:43 +08:00
parent de30d72c22
commit 1279ad4203
1 changed files with 1 additions and 0 deletions

View File

@ -276,6 +276,7 @@ public class GenericPOElementHandler extends AbstractElementHandler {
private void exportDetail(PIPOContext ctx, TransformerHandler document, GenericPO parent, int index, String[] tables) { private void exportDetail(PIPOContext ctx, TransformerHandler document, GenericPO parent, int index, String[] tables) {
AttributesImpl atts = new AttributesImpl(); AttributesImpl atts = new AttributesImpl();
tables[index] = tables[index].trim();
String sql = "SELECT * FROM " + tables[index] + " WHERE " + parent.get_TableName() + "_ID = ?"; String sql = "SELECT * FROM " + tables[index] + " WHERE " + parent.get_TableName() + "_ID = ?";
PreparedStatement pstmt = null; PreparedStatement pstmt = null;
ResultSet rs = null; ResultSet rs = null;