Browse Source

Fix : csv deleted column (#745)

* docs: new environment detail

Signed-off-by: Pranav C <pranavxc@gmail.com>

* fix: remove deleted column from csv

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/760/head
Pranav C 3 years ago committed by GitHub
parent
commit
4e0ddb62ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      packages/noco-docs/content/en/getting-started/installation.md
  2. 11
      packages/nocodb/src/lib/dataMapper/lib/sql/BaseModelSql.ts

2
packages/noco-docs/content/en/getting-started/installation.md

@ -151,7 +151,7 @@ And connection params for this database can be specified in `NC_DB` environment
| AWS_SECRET_ACCESS_KEY | No | For Litestream - S3 secret access key | If Litestream is configured and NC_DB is not present. SQLite gets backed up to S3 |
| AWS_BUCKET | No | For Litestream - S3 bucket | If Litestream is configured and NC_DB is not present. SQLite gets backed up to S3 |
| AWS_BUCKET_PATH | No | For Litestream - S3 bucket path (like folder within S3 bucket) | If Litestream is configured and NC_DB is not present. SQLite gets backed up to S3 |
| NC_EXPORT_MAX_TIMEOUT | No | After NC_EXPORT_MAX_TIMEOUT csv gets downloaded in batches | Default value 5000 will be used |
| NC_EXPORT_MAX_TIMEOUT | No | After NC_EXPORT_MAX_TIMEOUT csv gets downloaded in batches | Default value 5000(in millisecond) will be used |
### Docker Compose

11
packages/nocodb/src/lib/dataMapper/lib/sql/BaseModelSql.ts

@ -2525,7 +2525,16 @@ class BaseModelSql extends BaseModel {
}
}
const data = Papaparse.unparse({ fields, data: csvRows });
const data = Papaparse.unparse({
fields:
fields &&
fields.filter(
f =>
this.columns.some(c => c._cn === f) ||
this.virtualColumns.some(c => c._cn === f)
),
data: csvRows
});
return { data, offset, elapsed };
}

Loading…
Cancel
Save