LoginSignup
8
8

More than 5 years have passed since last update.

RedShiftの日本語あんちょこメモ

Last updated at Posted at 2013-07-03

サポートしていないPostgreSQLの機能

ここに記載されている。

データ型

とりあえず、範囲を追加

Data type Aliases Description 範囲
SMALLINT INT2 Signed two-byte integer -32768 to +32767
INTEGER INT, INT4 Signed four-byte integer -2147483648 to +2147483647
BIGINT INT8 Signed eight-byte integer -9223372036854775807 to 9223372036854775807
DECIMAL NUMERIC Exact numeric of selectable precision 可変長
REAL FLOAT4 Single precision floating-point number - 3.40E+38 ~ -1.18E-38、0、および 1.18E-38 ~ 3.40E+38
DOUBLE PRECISION FLOAT8 Double precision floating-point number
BOOLEAN BOOL Logical Boolean (true/false) TRUE, FALSE, NULL
CHAR CHARACTER Fixed-length character string 65535 bytes (64K -1)
VARCHAR CHARACTER VARYING Variable-length character string with a user-defined limit 65535 bytes (64K -1)
DATE Calendar date (year, month, day) 4713 BC to 5874897 AD(1 day)
TIMESTAMP Date and time (without time zone) 4713 BC to 5874897 AD(1 microsecond)

Copyコマンド

並び替え可能。
こんな感じ。

"Load data from a file with default values"

copy venue_new(venueid, venuename, venuecity, venuestate) 
from 's3://mybucket/data/venue_noseats.txt' 
credentials 'aws_access_key_id=<your-access-key-id>;
aws_secret_access_key=<your-secret-access-key>' 
delimiter '|';
  • Copy元ファイルに存在するカラムをスキップしてCopyすることはできない。
  • Datetime型のデータをDate型のカラムにCopyすることはできない。
8
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
8