kintone-labs / cli-kintone

GNU General Public License v2.0
49 stars 22 forks source link

Importing of input file creates empty records #14

Closed cadidevile closed 7 years ago

cadidevile commented 7 years ago

cli-kintone -a 47 -d domain.kintone.com -e utf-8 -t KEY -u User -p password -f c:\temp\kintone\newusers.csv

csv file created mulitple ways - via kintone export - AD export of Windows - manually created changed encoding - when it works creates new records of the exact number but empty.

dtduc91 commented 7 years ago

Dear cadidevile, Can I help you with this issue? Can you help me provide your CSV file? I will easy to detect your issue.

vonhunhu commented 7 years ago

Dear Mr/Ms cadidevile,

I tried to reproduce from your comment such as:

  1. Having an app (e.g. app ID =1 ) on kintone with some fields (e.g. add 2 fields such as: -A text field: Field name: Name; Field Code: Text -A number filed: Field name: ID; Field Code: Number)

  2. Export to file from kintone with filename is abc.csv The result of the exported file:

Record number ID Name
4 4 Nhi
3 3 Tuan
2 3 Loi
1 1 Hoa

※Header is using [Field name]

  1. Use cli-kintone for importing cli-kintone -a 1 -d domain.kintone.com -e utf-8 -t KEY -u User -p password -f abc.csv Result: These are 4 empty records imported.

  2. And then changing, the header of the imported from [Field name] to [Field Code], then re-import The import file will show as below:

Record number Number Text
4 4 Nhi
3 3 Tuan
2 3 Loi
1 1 Hoa

※Header is using [Field code]

Result: These are 4 records imported with full data.

Note: cli-kintone command is read data for importing by [Field code] Please help to double check your case using by [Field code] for importing and let me know your result. Thank you.