Skip to content

Instantly share code, notes, and snippets.

@WesleyBatista
WesleyBatista / 20181217_cockroach_bigserial_bigint_quick_study.md
Created December 17, 2018 14:27
Cockroach Bigserial and Bigint compatibility - Quick Study

Is the bigserial compatible with the bigint on Cockroach?

Create the tables

Let's create table_x with a bigserial column and set it as the primary key.

CREATE TABLE table_x (
	id bigserial PRIMARY KEY, 
import dateutil.parser
dates = [
# dates that comes as str from kafka message:
'2019-05-27T12:54:28.777652636Z',
'2019-05-27T12:54:28.128Z', # added
'2019-05-27T12:54:28.120Z', # added
'2019-05-27T12:54:28.100Z', # added
'2019-05-27T12:54:28.1Z', # added
'2019-05-27T12:54:29.993908166Z',
@WesleyBatista
WesleyBatista / raspberry_databases.md
Last active September 1, 2019 15:12
Running the main databases on raspberry pi

setup

mongo

  1. create the data dir mkdir -p /home/pi/mongo/data
  2. run the following docker command:
    docker run --restart always -d -p 27017:27017 -p 28017:28017 -e AUTH=no -v /home/pi/mongo/data:/data/db --name mongo izone/arm:mongo-3.0.9
    

    source: https://github.com/luvres/armhf

import clickhouse_driver
def execute_query(sql, settings):
conn_params = {
'host': '<HOST>',
'port': 9000,
'user': '<USER>',
'password': '<PASSWORD>',
'database': 'default',
package main
import (
"fmt"
)
type Base interface {
SetParams(string)
GetParams() string
}
@WesleyBatista
WesleyBatista / README.md
Last active November 1, 2021 14:51 — forked from antonydevanchi/README.md
Download all images from undraw.co/illustrations
@WesleyBatista
WesleyBatista / blockly.xml
Created September 15, 2021 20:02
New Marlowe Project
When
[Case
(Deposit
(Role "Seller")
(Role "Buyer")
(Token "" "")
(ConstantParam "Price")
)
(When
[Case