public int EkleUrunOzellik(TBLURUN_OZELLIKLERI ptUrunOzellik)
 {
     try
     {
         DbCommand dbcommand = db.GetSqlStringCommand("INSERT INTO TBLURUN_OZELLIKLERI(URUNID,OZELLIKID,DEGER) VALUES(@URUNID,@OZELLIKID,@DEGER) SELECT @@IDENTITY");
         db.AddInParameter(dbcommand, "URUNID", DbType.Int32, ptUrunOzellik.URUNID);
         db.AddInParameter(dbcommand, "OZELLIKID", DbType.Int32, ptUrunOzellik.OZELLIKID);
         db.AddInParameter(dbcommand, "DEGER", DbType.String, ptUrunOzellik.DEGER);
         return(db.ExecuteScalar(dbcommand).ToInt(0));
     }
     catch (Exception ex)
     {
         cLog.Write(ex, _iKullaniciID);
         return(0);
     }
 }
 public short DuzenleUrunOzellik(TBLURUN_OZELLIKLERI ptUrunOzellik)
 {
     try
     {
         DbCommand dbcommand = db.GetSqlStringCommand("UPDATE TBLURUN_OZELLIKLERI SET URUNID=@URUNID, OZELLIKID=@OZELLIKID, DEGER=@DEGER WHERE ID=@ID");
         db.AddInParameter(dbcommand, "ID", DbType.Int32, ptUrunOzellik.ID);
         db.AddInParameter(dbcommand, "URUNID", DbType.Int32, ptUrunOzellik.URUNID);
         db.AddInParameter(dbcommand, "OZELLIKID", DbType.Int32, ptUrunOzellik.OZELLIKID);
         db.AddInParameter(dbcommand, "DEGER", DbType.String, ptUrunOzellik.DEGER);
         db.ExecuteNonQuery(dbcommand);
         return(1);
     }
     catch (Exception ex)
     {
         cLog.Write(ex, _iKullaniciID);
         return(0);
     }
 }