易截截图软件、单文件、免安装、纯绿色、仅160KB

c# 操作mssql数据库 含有带参数sql语句运行

<?xml version="1.0" encoding="utf-8"?>
<configuration>
 <appSettings>
  <add key="Default" value="Default" />
 </appSettings>
 <connectionStrings>
  <add name="Default" connectionString="Data Source=192.168.1.197;User ID=diamond;Password=88888888;Initial Catalog=EmailAnalyse" providerName="System.Data.SqlClient" />
 </connectionStrings>
</configuration>
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Data.SqlClient;
using System.Collections.Generic;
using System.Text;
namespace OfficeOutlook
{
    /// <summary>
    ///DataBase 的摘要说明
    /// </summary>
    public class DataBase
    {
        protected SqlConnection BaseSqlConnection = new SqlConnection();//连接对象
        protected SqlCommand BaseSqlCommand = new SqlCommand();  //命令对象
        public DataBase()
        {
            //
            // TODO: 在此处添加构造函数逻辑
            //
        }
        protected void OpenConnection()
        {
            if (BaseSqlConnection.State == ConnectionState.Closed)  //连接是否关闭
                try
                {
           &nb


相关文档:

SQL output使用

SQL版:
alter proc testguo
(
    @cityid int,
    @cityname nvarchar(100) output
)
as
select @cityname =  city_name from BA_Hot_City where cityid = @cityid
select @cityname
go
declare @cityname nvarchar(100)
exec testguo 1,@cityname output
另一版:
ht ......

贺州市疾病预防控制中心SQL server数据库置疑成功修复

贺州市疾病预防控制中心所用的ZmSoft从业体检信息网络系统V2010.1.26 正式版采用SQL SERVER2000平台,不明原因,数据库"置疑“,客户试过所有网上方法,未能解决.沈阳凯文数据恢复中心SQL数据库工程师成功将其解决.
沈阳凯文数据恢复中心MS SQL SERVER研发小组致力于MsSql数据库技术的研究。经过多年研究完全掌握了S ......

c#操作access*转载

 
 
public static class AccessHelper
{
//数据库连接字符串
//WebForm
//public static readonly string conn_str = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + HttpContext.Current.Request.PhysicalApplicationPath + System.Configuration.ConfigurationManager ......

SQL语句 创建索引

语法:
CREATE [索引类型] INDEX 索引名称
ON 表名(列名)
WITH FILLFACTOR = 填充因子值0~100
GO
/*实例*/
USE 库名
GO
IF EXISTS
(SELECT * from SYSINDEXES WHERE NAME='IX_TEST_TNAME')--检测是否已经存在IX_TEST_TNAME索引
DROP INDEX
TEST.IX_TEST_TNAME--如果存在则删除
--创建索引
CREATE NONCLUSTER ......

SQL Server中“加锁选项”的功能说明

1   如何锁一个表的某一行  
   
   
  A   连接中执行  
   
  SET   TRANSACTION   ISOLATION   LEVEL   REPEATABLE   READ  
   
  begin   tran  
   
  selec ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号