03 2019 档案

to_char 函数将小数点前面的0舍掉的解决办法
摘要:to_char(val,'0.9') 9 代表一个数字 0 强制显示0 $ 放置一个$符 L 放置一个浮动本地货币符 . 显示小数点 , 显示千位指示符 最终只能嵌套两层 regexp_replace解决,内层处理正数,将.\d替换为0.\d;外层处理负数,将-.\d替换为-0. select re 阅读全文

posted @ 2019-03-23 19:53 mol1995 阅读(709) 评论(0) 推荐(0)

instr 函数从后往前计数 instr(spell,' ',-1)
摘要:update CY set last=substr(spell,instr(spell,' ',-1)); 阅读全文

posted @ 2019-03-15 09:02 mol1995 阅读(580) 评论(0) 推荐(0)

WordVBA常用项
摘要:将光标所在段落选中 Selection.MoveUp unit:=wdParagraphSelection.MoveDown unit:=wdParagraph, Extend:=wdExtend ' 选择当前行 Selection.HomeKey unit:=wdLine Selection.En 阅读全文

posted @ 2019-03-14 17:29 mol1995 阅读(388) 评论(0) 推荐(0)

整体读入cmd结果,而不是分行读入,效率极高
摘要:public static long GetDirectorySize(string path) { long res = 0; System.Diagnostics.Process p = new System.Diagnostics.Process(); p.StartInfo.FileName 阅读全文

posted @ 2019-03-02 14:53 mol1995 阅读(284) 评论(0) 推荐(0)

获取文件夹总大小方法2_获取cmd命令结果,效率最高
摘要:public static long GetDirectorySize(string path) { long res = 0; System.Diagnostics.Process p = new System.Diagnostics.Process(); p.StartInfo.FileName 阅读全文

posted @ 2019-03-02 14:52 mol1995 阅读(717) 评论(0) 推荐(0)

获取文件夹总大小方法1_递归,效率极低
摘要:public static long GetDirectoryLength(string dirPath) { //判断给定的路径是否存在,如果不存在则退出 if (!Directory.Exists(dirPath)) return 0; long len = 0; //定义一个Directory 阅读全文

posted @ 2019-03-02 14:32 mol1995 阅读(217) 评论(0) 推荐(0)

导航