Sybase Writer
Sybase Writer plugin implements the functionality of writing data to Sybase database tables.
Configuration Example
We can use Docker container to start a Sybase database
bash
docker run -tid --rm -h dksybase --name sybase -p 5000:5000 ifnazar/sybase_15_7 bash /sybase/startThen create a table as follows:
sql
create table addax_writer
(
id int,
name varchar(255),
salary float(2),
created_at datetime,
updated_at datetime
);Then use the following task configuration file:
json
{
"job": {
"setting": {
"speed": {
"bytes": -1,
"channel": 1
}
},
"content": {
"reader": {
"name": "streamreader",
"parameter": {
"column": [
{
"random": "100,1000",
"type": "long"
},
{
"random": "10,100",
"type": "string"
},
{
"random": "10,1000",
"type": "double"
},
{
"incr": "2022-01-01 13:00:00,2,d",
"type": "date"
},
{
"incr": "2023-01-01 13:00:00,2,d",
"type": "date"
}
],
"sliceRecordCount": 100
}
},
"writer": {
"name": "sybasewriter",
"parameter": {
"username": "sa",
"password": "password",
"column": [
"id",
"name",
"salary",
"created_at",
"updated_at"
],
"connection": {
"jdbcUrl": "jdbc:sybase:Tds:127.0.0.1:5000/master",
"table": [
"dbo.addax_writer"
]
}
}
}
}
}
}Parameters
This plugin is based on RDBMS Writer, so you can refer to all configuration items of RDBMS Writer.