The best way to batch load data into KingbaseES database

Foreword This article discusses methods for batch loading data in the Kingbase ES database server, as well as best practices for initial data loading and incremental data loading in an empty database. Batch loading method The following data loading methods are listed from most time-consuming to least time-consuming: 1. Run the single-record INSERT command. 2. […]

Experiment report 1: Use of database tools and creation and management of databases

Use of database tools and database creation and management 1. Experiment purpose 1. Master database definition and deletion. 2. Master the definition, modification and deletion of basic tables. 3. Master adding and deleting constraints. 2. ExperimentContent Operating system: Windows 10 Database management system: SQL Server 2017 SQL Server database creation The reference is the content […]

Use grafana to display data in SQLite database tables

1. Environment preparation yum -y install epel-release yum -y install sqlite sqlite-devel yum -y install python-pip pip install –upgrade setuptools yum list available python* | grep paramiko yum -y install python-paramiko yum -y install python2-requests 2. Script # !/usr/local/python3.8/bin/python3 # -*- coding:UTF-8 -*- import sqlite3 import re def dict_factory(cursor, row): # Process the data obtained […]

KingbaseES V8R6 cluster case—one master and two backup architecture single standby database outage impact test

KingbaseES V8R6 cluster case—one master and two backup architecture single standby database outage impact test Case description: For the KingbaseES V8R6 cluster, in sync mode, for a one-master-one-standby architecture, if the standby database is down, the master database transaction commit will be hung. After the wal_sender_timeout parameter (default 60s) exceeds the threshold, sync is converted […]

Suggestions on adding primary keys and indexes to KingbaseES database partition tables

1. Initialize the test environment # Database version information KingbaseES V008R006C007B0012 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-46), 64-bit 1. Create partition table: create table tb(id bigint,stat date,no bigint,pdate date,info varchar2(50)) partition by range(pdate) INTERVAL (‘1 MONTH’::INTERVAL) ( PARTITION tb_p0 VALUES LESS THAN (‘2019-01-01’), PARTITION tb_p1 VALUES LESS THAN (‘2019-02-01’), PARTITION […]

MySqlC# database backup and restore

public static class SQLBackup { /// <summary> /// Execute Cmd command /// </summary> /// <param name=”workingDirectory”>Directory of the process to be started</param> /// <param name=”command”>Command to be executed</param> public static void StartCmd(String workingDirectory, String command) {<!– –>     using (Process p = new Process())     {     p.StartInfo.FileName = “cmd.exe”; p.StartInfo.WorkingDirectory = workingDirectory; p.StartInfo.UseShellExecute = false; p.StartInfo.RedirectStandardInput = […]

KingbaseES database adaptation Activiti7 didn’t put process definition problem handling process

1. Introduction to Activiti Activiti is a lightweight java open source BPMN 2 workflow engine. It is currently upgraded to 7.x and supports integration with springboot2.x. 2. Project environment Spring Boot version 2.2.5 Activiti version 7.1.x Source database: MySQL 5.7 Target database: KinbgaseES V008R006C007B0024 JDBC driver: JDBC driver in Postgre form, postgresql-42.2.9.jar 3. Error messages […]

Database: Hive to Presto (3)

Continue with the previous section of code. import re import os import tkinter.filedialog from tkinter import * class Hive2Presto: def __int__(self): self.t_funcs = [‘substr’, ‘nvl’, ‘substring’, ‘unix_timestamp’] + \ [‘to_date’, ‘concat’, ‘sum’, ‘avg’, ‘abs’, ‘year’, ‘month’, ‘ceiling’, ‘floor’] self.time_funcs = [‘date_add’, ‘datediff’, ‘add_months’] self.funcs = self.t_funcs + self.time_funcs self.current_path = os.path.abspath(__file__) self.dir = os.path.dirname(self.current_path) self.result […]

go language and redis database

1 Interact with redis database through go language Installation command go get After the installation is completed, create test.go in the home directory, copy the following code into test.go, compile and execute test.go, and then find the key c1 value in redis as hello, indicating that the installation is successful. package main import (“”) […]