public static string addNew(string strXml) { DataDoc doc = new DataDoc(strXml); // 创建执行对象 DataStorage storage = new DataStorage(); int size = doc.getDataNum(Table.USERLIST); // 解析sql语句 for (int i = 0; i < size; i++) { XmlElement ele = (XmlElement)doc.getDataNode(Table.USERLIST, i); string a = ele.InnerXml; XmlNode node = XmlFun.getNode(ele, Field.USERID); string strId = NumAssign.assignID_A("000002"); XmlFun.setNodeValue(node, strId); storage.addSQL(SQLAnalyse.analyseXMLSQL(ele)); } // 执行 string strReturn = storage.runSQL(); ReturnDoc returndoc = new ReturnDoc(); if (!General.empty(strReturn)) { returndoc.addErrorResult(Common.RT_FUNCERROR); returndoc.setFuncErrorInfo(strReturn); } else { returndoc.addErrorResult(Common.RT_SUCCESS); } return(returndoc.getXml()); }