Esempio n. 1
0
        public void InsertPara(T_PARA PARA)
        {
            string sql = string.Empty;

            sql = "insert into T_PARA (ID,T_DOC_ID,PARA,SORT_ID)" +
                  " values(" +
                  "NULL,'" + PARA.T_DOC_ID + "','" + PARA.PARA + "','" + PARA.SORT_ID + "')";

            gt.SetBySQL(sql);
        }
Esempio n. 2
0
        public void InsertDoc(T_Doc Tdoc)
        {
            string sql = string.Empty;

            sql = "insert into t_doc (DocTitle,Doc,CreateDate,InsetDate,UserID,Address,Keywords,DOCTREE_ID,FullDoc)" +
                  " values(" +
                  "'" + Tdoc.DocTitle + "','" + Tdoc.Doc + "','" + Tdoc.CreateDate + "','" + Tdoc.InsetDate +
                  "','" + Tdoc.UserID + "','" + Tdoc.Address + "','" + Tdoc.Keywords + "','" + Tdoc.DOCTREE_ID + "','" +
                  Tdoc.FullDoc + "')";
            gt.SetBySQL(sql);

            if (Tdoc.blobDoc != null)
            {
                sql = "Update t_doc SET blobData = @img where ID=" + gt.GetLastInsertID("T_Doc");
                gt.SetBlob(sql, Tdoc.blobDoc);
            }
        }
Esempio n. 3
0
 public int AddNodeAndGetId(T_DocTree DT)
 {
     // string sql = "SELECT last_insert_rowid()";
     gt.SetBySQL("INSERT INTO T_DOCTREE	(ID,PID, NodeTitle, NodeType)VALUES (null,"+ DT.PId + ",' " + DT.NodeTitle + "', '" + DT.NodeType.ToString() + "')");
     return(int.Parse(gt.GetLastInsertID("T_DOCTREE")));
 }