#### # 日常命令记录

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36

    #windows系统修复
    DISM.exe /Online /Cleanup-image /Scanhealth
    DISM.exe /Online /Cleanup-image /Restorehealth
    sfc /scannow

    #windows网络修复
    netsh winsock reset

    #合并ts文件
    copy /b c:\Users\hito\Downloads\*.ts d:\50.mp4

    #windows11家庭版安装Hyper-V（以下命令拷贝到txt文本后重命名为bat文件然后用管理员权限运行）
    pushd "%~dp0"
    dir /b %SystemRoot%\servicing\Packages\*Hyper-V*.mum >> hyper-v.txt
    for /f %%i in ('findstr /i . hyper-v.txt 2^>nul') do dism /online /norestart /add-package:"%SystemRoot%\servicing\Packages\%%i"
    del hyper-v.txt
    Dism /online /enable-feature /featurename:Microsoft-Hyper-V-All /LimitAccess /ALL

    #mysql查看索引使用情况
    EXPLAIN SELECT A.XXX, B.XXX FROM TABLE1 A, TABLE2 B ON A.XXX = B.XXX;

    #mysql使用触发器插入数据自动生产uuid主键
    insert_before  BEFORE  插入
    BEGIN
    			SET NEW.ID = REPLACE(UUID(),"-","");
    END

    #excel
    #合并
    =CONCATENATE("EX010",D2,C2,"1")
    #截断
    =LEFT(E2,6)
    #判断取值
    =IF(O2="宜都市","420500000000000",IF(O2="高新区","420592000000000",IF(O2="枝江市","420583000000000",IF(O2="当阳市","420582000000000",IF(O2="远安县","420525000000000",IF(O2="兴山县","420526000000000",IF(O2="秭归县","420527000000000",IF(O2="长阳","420528000000000",IF(O2="五峰县","420529000000000",IF(O2="夷陵区","420506000000000",IF(O2="点军区","420504000000000",IF(O2="西陵区","420502000000000",IF(OR(ISNUMBER(FIND({"伍家";"伍家区";"伍家岗区"},O2))),"420503000000000",IF(OR(ISNUMBER(FIND({"猇亭";"猇亭区"},O2))),"420505000000000"))))))))))))))
    #经纬度计算
    =LEFT(T2,FIND("°",T2)-1)+MID(T2,FIND("°",T2)+1,FIND("′",T2)-FIND("°",T2)-1)/60+MID(T2,FIND("′",T2)+1,FIND("″",T2)-FIND("′",T2)-1)/3600

命令