embulk-input-sqlserver 0.6.4 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -2
- data/classpath/{embulk-input-jdbc-0.6.4.jar → embulk-input-jdbc-0.7.0.jar} +0 -0
- data/classpath/embulk-input-sqlserver-0.7.0.jar +0 -0
- data/src/main/java/org/embulk/input/SQLServerInputPlugin.java +2 -2
- metadata +4 -4
- data/classpath/embulk-input-sqlserver-0.6.4.jar +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 69d0ef968a3614fd3e709e0ec5ae328c590eb1a9
|
4
|
+
data.tar.gz: 646632ea8e7020effa9cf76bca0f498a0b99c993
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a2c5c6fa179400425752e2a5ed183b1f6eb19282bb88fb603e3ea93c97b139db390d0cd4af1cc7b8e75bcb4eb52723a04766a44abf11bdc622edbfc931de8d76
|
7
|
+
data.tar.gz: 167af326925613fc6b6c27ae43b4c8909d2545ce74709c5d10bd13e6065ccbdb7b5ee804987d2a1e9aae2833de0f7c288004a570479f8fad4b995db036a39542
|
data/README.md
CHANGED
@@ -35,13 +35,14 @@ embulk "-J-Djava.library.path=C:\drivers" run input-sqlserver.yml
|
|
35
35
|
- **default_timezone**: If the sql type of a column is `date`/`time`/`datetime` and the embulk type is `string`, column values are formatted int this default_timezone. You can overwrite timezone for each columns using column_options option. (string, default: `UTC`)
|
36
36
|
- **column_options**: advanced: a key-value pairs where key is a column name and value is options for the column.
|
37
37
|
- **value_type**: embulk get values from database as this value_type. Typically, the value_type determines `getXXX` method of `java.sql.PreparedStatement`.
|
38
|
-
(string, default: depends on the sql type of the column. Available values options are: `long`, `double`, `float`, `decimal`, `boolean`, `string`, `date`, `time`, `timestamp`)
|
38
|
+
(string, default: depends on the sql type of the column. Available values options are: `long`, `double`, `float`, `decimal`, `boolean`, `string`, `json`, `date`, `time`, `timestamp`)
|
39
39
|
- **type**: Column values are converted to this embulk type.
|
40
|
-
Available values options are: `boolean`, `long`, `double`, `string`, `timestamp`).
|
40
|
+
Available values options are: `boolean`, `long`, `double`, `string`, `json`, `timestamp`).
|
41
41
|
By default, the embulk type is determined according to the sql type of the column (or value_type if specified).
|
42
42
|
- **timestamp_format**: If the sql type of the column is `date`/`time`/`datetime` and the embulk type is `string`, column values are formatted by this timestamp_format. And if the embulk type is `timestamp`, this timestamp_format may be used in the output plugin. For example, stdout plugin use the timestamp_format, but *csv formatter plugin doesn't use*. (string, default : `%Y-%m-%d` for `date`, `%H:%M:%S` for `time`, `%Y-%m-%d %H:%M:%S` for `timestamp`)
|
43
43
|
- **timezone**: If the sql type of the column is `date`/`time`/`datetime` and the embulk type is `string`, column values are formatted in this timezone.
|
44
44
|
(string, value of default_timezone option is used by default)
|
45
|
+
- **after_select**: if set, this SQL will be executed after the SELECT query in the same transaction.
|
45
46
|
|
46
47
|
## Example
|
47
48
|
|
@@ -94,6 +95,7 @@ in:
|
|
94
95
|
column_options:
|
95
96
|
col1: {type: long}
|
96
97
|
col3: {type: string, timestamp_format: "%Y/%m/%d", timezone: "+0900"}
|
98
|
+
after_select: "update my_table set col5 = '1' where col4 != 'a'"
|
97
99
|
|
98
100
|
```
|
99
101
|
|
Binary file
|
Binary file
|
@@ -89,8 +89,8 @@ public class SQLServerInputPlugin
|
|
89
89
|
}
|
90
90
|
StringBuilder urlBuilder = new StringBuilder();
|
91
91
|
if (sqlServerTask.getInstance().isPresent()) {
|
92
|
-
urlBuilder.append(String.format("jdbc:sqlserver://%s\\%s
|
93
|
-
sqlServerTask.getHost().get(), sqlServerTask.getInstance().get()
|
92
|
+
urlBuilder.append(String.format("jdbc:sqlserver://%s\\%s",
|
93
|
+
sqlServerTask.getHost().get(), sqlServerTask.getInstance().get()));
|
94
94
|
} else {
|
95
95
|
urlBuilder.append(String.format("jdbc:sqlserver://%s:%d",
|
96
96
|
sqlServerTask.getHost().get(), sqlServerTask.getPort()));
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: embulk-input-sqlserver
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sadayuki Furuhashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-03-29 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Selects records from a table.
|
14
14
|
email:
|
@@ -22,8 +22,8 @@ files:
|
|
22
22
|
- lib/embulk/input/sqlserver.rb
|
23
23
|
- src/main/java/org/embulk/input/SQLServerInputPlugin.java
|
24
24
|
- src/main/java/org/embulk/input/sqlserver/SQLServerInputConnection.java
|
25
|
-
- classpath/embulk-input-jdbc-0.
|
26
|
-
- classpath/embulk-input-sqlserver-0.
|
25
|
+
- classpath/embulk-input-jdbc-0.7.0.jar
|
26
|
+
- classpath/embulk-input-sqlserver-0.7.0.jar
|
27
27
|
homepage: https://github.com/embulk/embulk-input-jdbc
|
28
28
|
licenses:
|
29
29
|
- Apache 2.0
|
Binary file
|