see also http://labs.vmware.com/flings/onyx
</div> //create new xml-variable with E4X-syntax var xmlcontent = <vms></vms>; //E4X: create XML-Child Element: VM xmlcontent.vm.@uuid = uuid; xmlcontent.vm.name = vmname; xmlcontent.vm.cpus = numCpus; xmlcontent.vm.memory = memSize; xmlcontent.vm.ip = guestIpAddress; xmlcontent.vm.hostname = guestHostname; //log for sure : - ) System.debug(xmlcontent);
var main = new JDBCConnection(); var con; try { con = main.getConnection( url, user, password ); System.log( "Connection to database successful" ); var cstmt = con.prepareCall("{call nameOfStoredProcedure(?,?)}"); cstmt.setString(1,firstParameter); cstmt.setString(2, anotherParameter); var rs = cstmt.executeQuery(); //removed line, see comment //removed line, see above, and then the comment :) while ( rs.next() ) { //... Process results of the Stored Procedure, if necessary. } rs.close(); cstmt.close(); } catch( ex ) { throw "Exception during database action " + ex + ")"; } finally { if (con) { con.close(); }