This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM postgres:14 | |
ENV POSTGRES_PASSWORD=postgres | |
ENV POSTGRES_USER=postgres | |
# Fixed ownership and mode | |
RUN chown root:ssl-cert /etc/ssl/private/ssl-cert-snakeoil.key | |
RUN chmod 740 /etc/ssl/private/ssl-cert-snakeoil.key | |
CMD ["-c", "ssl=on", "-c", "ssl_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem", "-c", "ssl_key_file=/etc/ssl/private/ssl-cert-snakeoil.key"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://twitter.com/hiroysato/status/1339925551167893504 | |
FROM openjdk:8-slim | |
ENV LANG=C.UTF-8 \ | |
PATH_TO_EMBULK=/opt/embulk \ | |
PATH=${PATH}:/opt/embulk | |
# Change timezone | |
RUN ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with subset as ( | |
select '123−4567' as x union all -- 123−4567 | |
select '㌶' as x union all -- ヘクタール | |
select '㈱㈲' as x union all -- (株)(有) | |
select 'アイウエオABCabc①' as x union all -- アイウエオabcabc1 | |
select '〒〠〶' as x union all -- 〒〠〒 | |
select '()()' as x union all -- ()() | |
select 'ABCabc' | |
) | |
select x, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"context" | |
"fmt" | |
"cloud.google.com/go/bigquery" | |
) | |
// Item represents a row item. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package transformer | |
import ( | |
"bufio" | |
"encoding/csv" | |
"encoding/json" | |
"fmt" | |
"io" | |
"os" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"cloud.google.com/go/bigquery" | |
"context" | |
"fmt" | |
"google.golang.org/api/iterator" | |
"log" | |
"os" | |
"time" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"encoding/csv" | |
"encoding/json" | |
"fmt" | |
"io" | |
"log" | |
"strings" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"encoding/json" | |
"errors" | |
"io/ioutil" | |
"log" | |
) | |
type Runner interface { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"cloud.google.com/go/bigquery" | |
"context" | |
"fmt" | |
"google.golang.org/api/option" | |
) | |
func showBqDatasets() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"math/rand" | |
"time" | |
) | |
func Swap(arr *[]int, i int, j int) { | |
(*arr)[i], (*arr)[j] = (*arr)[j], (*arr)[i] |
NewerOlder