NetSuite Data Provider - Online Help
NetSuite Data Provider
Questions / Feedback?

INSERT Statements

To insert into a table, use the standard INSERT SQL syntax.

String cmd = "INSERT INTO Account (AcctName) VALUES (?)";
PreparedStatement pstmt = connection.prepareStatement(cmd,Statement.RETURN_GENERATED_KEYS);
pstmt.setString(1, "Petty Cash");
int count = pstmt.executeUpdate();
System.out.println(count+" rows are affected");
ResultSet rs = pstmt.getGeneratedKeys();
while(rs.next()){	  
  System.out.println(rs.getString("Id"));
}
connection.close();	

 
 
Copyright (c) 2015 RSSBus, Inc. - All rights reserved.
Build 1.0.5577.0