![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
随笔
QQ75026717
这个作者很懒,什么都没留下…
展开
-
SQL删除重复数据保留一条
delete Patientfrom Patient as aaleft join (select min(id) as id from Patientgroup by patientid) as bbon aa.id = bb.idwhere bb.id is null原创 2021-11-19 13:48:21 · 543 阅读 · 0 评论 -
SQLServer 清缓存
–清除存储过程缓存DBCC FREEPROCCACHE–清除会话缓存DBCC FREESESSIONCACHE–清除系统缓存DBCC FREESYSTEMCACHE(‘All’)–清除所有缓存DBCC DROPCLEANBUFFERS原创 2021-05-13 14:57:01 · 181 阅读 · 0 评论 -
sql server调用webservice脚本
declare @ServiceUrl varchar(200)set @ServiceUrl=‘http://localhost:180/xxx.asmx/Sync?Comd=’+@Comd+’&input=’+@input+’’–Webservice 地址,方法名称,入参。Declare @Object as IntDeclare @ResponseText as nvarchar(4000)EXEC sp_OACreate ‘MSXML2.XMLHTTP’, @Object OUT原创 2020-12-14 11:11:37 · 297 阅读 · 0 评论 -
SQL Server创建任务计划脚本
/****** Object: Job [任务名称] Script Date: 2020/12/11 10:30:18 /BEGIN TRANSACTIONDECLARE @ReturnCode INTSELECT @ReturnCode = 0/ Object: JobCategory [[Uncategorized (Local)]]] Script Date: 2020/12/11 10:30:18 ******/IF NOT EXISTS (SELECT name FROM原创 2020-12-14 11:07:49 · 368 阅读 · 0 评论 -
sql server 事件探查器只跟踪某客户端进程的事件
原创 2020-11-12 14:57:45 · 378 阅读 · 0 评论 -
C# HttpClient访问webapi 和 WebClient访问webservice 方法,
仅用于自己记录一下。方便以后使用。如有雷同,实属巧合public class ServiceUtility{private const string VERIFY_REISTPATIENTIMG_API_URI = “/api/Verify/ReistPatientImg”; #region 动态调用 /// <summary> /// 实例化WebServices /// </summary> /// <param name="原创 2020-11-04 16:28:45 · 1761 阅读 · 0 评论 -
C#用WebRequest访问webapi传送JSON串的方法
public static string CallWebApi(string Uri, string RequestJson){//请求路径string url = Uri; //定义request并设置request的路径 WebRequest request = WebRequest.Create(url); request.Method = "post"; //初始化request参数 string postDat原创 2020-11-04 16:08:19 · 432 阅读 · 0 评论 -
C# DictionaryValue做为Action时怎么使用
代码比较简单。随便建一个窗体类就行public partial class Form1 : Form{public Form1(){InitializeComponent();}Dictionary<string, Action> BtnActions;private void Form1_Load(object sender, EventArgs e){BtnActions = new Dictionary<string, Action> {{“处理”,Pro原创 2020-11-04 16:04:08 · 330 阅读 · 0 评论 -
sql 根据出生日期 计算年龄 本年按出生日期是否加1
SELECT CASE WHEN FLOOR(DATEDIFF(DY,‘1973-10-31’,GETDATE())/365.25) = 0 THEN ‘’ + CONVERT(VARCHAR, 1) ELSE ‘’ + CONVERT(VARCHAR, FLOOR(DATEDIFF(DY,‘1973-10-31’,GETDATE())/365.25)) END AS Age原创 2020-10-30 10:09:53 · 543 阅读 · 0 评论 -
C# dataTable常用处理
var l2 = dt.AsEnumerable().ToList().Select(x => x.Field(“ID”)).ToList();DataTable new dt = new DataTable();newdt = dt.Clone(); // 克隆dt 的结构,包括所有 dt 架构和约束,并无数据;DataRow[] rows = dt.Select(conditions); // 从dt 中查询符合条件的记录;DataTable.Select(“City Like ‘B%’”原创 2020-10-29 18:07:31 · 405 阅读 · 0 评论 -
C# Winform重写DataGridView 有兴趣可以留言交流
//[ToolboxBitmap(typeof(DataGrid))]public partial class UCDataGridView : DataGridView{//鼠标移动进来改变颜色private bool _CellColorOnchange = false;private bool _PaintCell = true;private bool _canRefresh = true;private List _columns = new List();//鼠标移动到行上时的颜原创 2020-10-29 14:04:52 · 681 阅读 · 0 评论 -
GIT 常用命令
git statusgit diffgit checkout – “文件路径” 撤销文件git diff +shift+insertgit add .//git pullgit commiti 进入vi编辑写注释esc退出:wqgit pull原创 2020-10-29 14:02:52 · 77 阅读 · 0 评论 -
sql server两表联合更新
update test1set test1.name=test2.name,test1.age=test2.agefrom test1inner join test2on test1.id=test2.id原创 2020-10-29 13:54:41 · 2380 阅读 · 1 评论 -
SqlServer Json解析 函数
自己写的,相目中用到的取某一JSON字段中,某个字字段的值。SELECT tt.Pat_ID,tt.a,tt.b,tt.a-tt.b AS execCount FROM (SELECT Pat_ID,CONVERT(INT,SUBSTRING(SUBSTRING(Step_4_Infor,CHARINDEX(‘Fractions_Tx":’, Step_4_Infor) + 15,CHARINDEX(’",“ProgressDetail’, Step_4_Infor)- CHARINDEX(原创 2020-10-29 13:50:57 · 488 阅读 · 0 评论