大数据
-
修改Oracle字符集
前言:两个不同的Oracle数据库服务之间导库,需要字符集匹配。 本案例以修改为ZHS16GBK字符集为例。 查看Oracle字符集: SQL> SELECT USERENV('language') FROM DUAL; 1. sysdba登录数据库 [o…
-
一键编译安装Redis脚本
#!/bin/bash . /etc/init.d/functions VERSION=redis-5.0.7 PASSWORD=123456 INSTALL_DIR=/usr/lcoal/redis install() { yum -y install gcc jemalloc-devel || { action "安装软件包失败,请检查网络配置" false ;…
-
redis cluster三主三从搭建
redis cluster三主三从搭建 1.1 安装C/C++环境 Redis编译时需要使用C/C++环境: yum install -y gcc gcc-c++ make 2.1 redis下载 wget https://download.redis.io/releases/redis-5.0.13.tar.gz 3.1 解压、编译 //…
-
mysql 复制一个库
首先创建一个库 new_db 然后使用mysqldump工具把老的库数据复制到新库 打开黑框 mysqldump old_db -uroot -p'12345' --add-drop-table | mysql new_db -u root -p'12345' root 是用户名 12345是密码 如果不在一…
-
sql 2008 r2 重新安装时提示 MsiGetProductInfo 无法检索 Product Code 为“{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}”
问题:sql 2008 r2 重新安装时提示 MsiGetProductInfo 无法检索 Product Code 为“{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}”解决办法:win+r 输入regedit回车找到注册表中的项目HHKEY_CLASSES_ROOT/Installer/Upgrad…
-
Linux mysql数据库自动备份脚本策略
1.创建保存备份文件的文件夹 mkdir /data/mysqlbak 2.编写脚本 cd /data/mysqlbakvi sqlAutoBak.sh SH脚本内容: DB_USER="root" DB_PASS="root" #你的数据库密码DB_HOST="localhost" DB_NAME="test" #你要备份的…
-
sqlserver 时间格式函数详细
--getdate 获取当前时间 select getdate() --dateadd 原有时间加: 2013-02-17 13:20:16 此时间加12个月 select dateadd(MONTH,12,'2013-02-17 13:20:16') --返回:2014-02-17 13:20:16.000 (参数month可以改为 da…
-
如何根据已有的数据库sql文件,逆向生成模型类?
这个情况是,我们已经在navicat工具上已经建立了一个数据库和若干数据表,然后我们在pycharm中与数据库建立连接得到了数据库的信息,但是因为是直接连接数据库取得的数据表信息,所以在应用的models模型类中并不存…
-
sqlserver reporting service造成cpu某核占用100%
Windows Server 2019的操作系统,双cpu共64线程 打开任务管理器的cpu界面,发现第3个核占用100%,其他核心都很低只有2%左右,本是开发服务器,没有多少访问量。这个问题发现多次,对系统响应也没什么影响,一直没发…
-
[Oracle] LeetCode 696 Count Binary Substrings
Given a binary string s, return the number of non-empty substrings that have the same number of 0's and 1's, and all the 0's and all the 1's in these substrings are grouped consecutively. Substrings …