
Loading CSV Into MongoDB With mongoimport and Types
Load a CSV into MongoDB with mongoimport: what its type guessing does to zip codes, how to declare types, skip blanks and upsert on a key, with real runs.
Tag
44 posts

Load a CSV into MongoDB with mongoimport: what its type guessing does to zip codes, how to declare types, skip blanks and upsert on a key, with real runs.

Two ways to load a CSV into DynamoDB: the S3 import that makes a table of string attributes, and a boto3 batch writer with Decimal numbers.

Load a CSV into Oracle with SQL*Loader: a control file for quotes and dates, the bad and log files, exit codes, direct path and external tables.

Load a CSV into SQL Server with BULK INSERT: FORMAT CSV for quoted fields, FIRSTROW, UTF-8, error files, server paths and permissions.

Load CSV into ClickHouse with clickhouse-client and FORMAT CSVWithNames, tune delimiter, errors and dates, and check a file first with clickhouse-local.

Load CSV into Snowflake with a file format, a stage and COPY INTO, then read the errors: ON_ERROR, VALIDATION_MODE, VALIDATE and the 64 day skip rule.

Load a CSV from Cloud Storage into BigQuery with bq load: explicit schema, bad-record limits, quoted newlines, replace versus append and a job ID for reruns.

How to load CSV into BigQuery, Snowflake and ClickHouse: stage the file, declare the schema, pick an error policy, load once and check the counts afterward.

Load a CSV into SQLite with one sqlite-utils command, set a primary key, control type detection, add full-text search, and see what 2 million rows cost.

PostgreSQL COPY has a CSV format and a text format that differ in delimiter, NULL marker and escaping. See the same rows in both and what a mismatch loads.

Four ways to load a CSV stored in S3 into a database: a streamed pipe, the RDS aws_s3 extension, DuckDB reading s3:// directly, and a download-then-load job.

Load a JSON Lines file into a PostgreSQL jsonb column with COPY. The backslash trap in text format, the csv-format fix, bad-line errors and timings.