Skip to content

Instantly share code, notes, and snippets.

---------------------------------------------------------------
user join t1, fts1:
QUERY PLAN
|--SCAN fts1 VIRTUAL TABLE INDEX 32:M6
|--SEARCH t1 USING INTEGER PRIMARY KEY (rowid=?)
`--SEARCH u USING INTEGER PRIMARY KEY (rowid=?)
real 0m0,225s
user 0m0,212s
---------------------------------------------------------------
1 match:
QUERY PLAN
|--SCAN fts1 VIRTUAL TABLE INDEX 32:M5
|--SEARCH t1 USING INTEGER PRIMARY KEY (rowid=?)
`--SEARCH u USING INTEGER PRIMARY KEY (rowid=?)
real 0m0,173s
user 0m0,158s
---------------------------------------------------------------
user join 1 entity:
QUERY PLAN
|--SCAN fts1 VIRTUAL TABLE INDEX 32:M6
|--SEARCH t1 USING INTEGER PRIMARY KEY (rowid=?)
`--SEARCH u USING INTEGER PRIMARY KEY (rowid=?)
real 0m0,248s
user 0m0,239s
DoctorScheduleExclusion:
table: PL_EXCL
properties:
Id:
column: PL_EXCL_ID
OwnerType:
column: OWNER_TYPE
OwnerId:
column: OWNER_ID
Name:
using System.Collections.Generic;
using System.Linq;
using System.Diagnostics;
using gudusoft.gsqlparser;
using System;
public static class ParseSql
{
public class ColumnInfo
{
using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Running;
namespace SpanBench
{
class Program
{
static void Main(string[] args)
{
//BenchmarkRunner.Run<BenchmarkDemo1>();
@swvitaliy
swvitaliy / README.md
Created November 1, 2022 12:20
Bad nw connection hotfix

One liner - restart nw connection on failed

while true; do nc ya.ru 80 && service network-manager restart; T=$(date '+%H:%m:%S'); echo "${T} restarting"; sleep 10; done

Вместо service network-manager restart можно так же указать

nmcli networking off 
@swvitaliy
swvitaliy / ifconfig.go
Created March 7, 2023 13:43
ifconfig.go
package main
//
// Print network interface information
//
import (
"fmt"
"net"
"strings"
const range = (arr, start, len) => {
len = len || Math.max(0, arr.length - start);
const end = Math.min(arr.length, start + len);
return {
current: start,
length: len,
next: function() {
if (this.current >= end) return {done: true};
else return {done: false, value: arr[this.current++]};
},
@swvitaliy
swvitaliy / Makefile
Last active September 23, 2023 20:05
build:
g++ -std=c++14 -Wall -O2 -oa a.cpp
naive:
sudo perf stat -B -e cache-misses ./a n
better:
sudo perf stat -B -e cache-misses ./a b