View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004901 | JEDI VCL | 00 JVCL Components | public | 2009-08-22 15:26 | 2009-10-03 14:25 |
Reporter | dcabale | Assigned To | AHUser | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | Daily / GIT | ||||
Target Version | Fixed in Version | 3.39 | |||
Summary | 0004901: [TJvCsvDataSet] loading successively different csv files in a same TJvCsvDataSet fires un unexpected exception | ||||
Description | Hi, all is told in the title, but you can make the following test: 1. create 2 .csv files: //////////// test1.csv //////////// name,address1,address2 didier,"37, Av.",condom //////////// end of file ////////// //////////// test2.csv //////////// name,address3,address4 didier,"37, Av.",condom //////////// end of file ////////// Note that these files have not the same field names 2. On a Button click, code what follows: //////////// code ///////////////// JvCsvDataSet1.LoadFromFile('test1.csv'); JvCsvDataSet1.LoadFromFile('test2.csv'); //////////// end of code ////////// Execute this code. Then an unexpected exception telling that "Field address1 in file, but not in field definitions" is fired. This exception is unexpected, because procedure LoadFromFile first 'Closes' the dataset, and should forget all of what has been previously loaded. | ||||
Additional Information | as a fix, modify procedure TJvCustomCsvDataSet.InternalInitFieldDefs as follows: ... // existing code FieldDefs.Clear; // Clear VCL Database field definitions FCsvColumns.Clear; // Clear our own CSV related field Data ////////////////////////////////////////// /// added by DCA on 22/08/2009 FHeaderRow := ''; /// end of adding // existing code aCsvFieldDef := CsvFieldDef; ... | ||||
Tags | JvCSVDataset, LoadFromFile | ||||
|
Hello, We would really like to have the zipped sources of a sample application showing this, along with the csv files. |
2009-09-11 16:04
|
LoadSuccessiveToJvCsvDataset.zip (1,472 bytes) |
|
Please find it above. Best regards |
|
See also 0004935 |
|
This is now fixed in SVN. |
|
Didier tells me that this is not solved. He will add a not here detailing this. |
|
JvCsvData.pas 12499 2009-09-14 18:48:01Z out of JVCL3-Source-2009-10-02.zip does not fix the bug. To show this, please run the project in the attached file. |
|
Looks like you must wait for the 2009-10-03 daily build. I changed the file yesterday and 2009-09-14 isn't yesterday ;-) |
Date Modified | Username | Field | Change |
---|---|---|---|
2009-08-22 15:26 | dcabale | New Issue | |
2009-09-09 19:34 | obones | Note Added: 0016065 | |
2009-09-09 19:34 | obones | Status | new => feedback |
2009-09-11 16:03 | dcabale | Tag Attached: JvCSVDataset | |
2009-09-11 16:03 | dcabale | Tag Attached: LoadFromFile | |
2009-09-11 16:04 | dcabale | File Added: LoadSuccessiveToJvCsvDataset.zip | |
2009-09-11 16:06 | dcabale | Note Added: 0016089 | |
2009-09-14 12:24 | JeremyKnowles | Note Added: 0016098 | |
2009-09-14 14:01 | obones | Relationship added | related to 0004935 |
2009-10-02 10:59 | AHUser | Note Added: 0016219 | |
2009-10-02 10:59 | AHUser | Status | feedback => resolved |
2009-10-02 10:59 | AHUser | Fixed in Version | => Daily / SVN |
2009-10-02 10:59 | AHUser | Resolution | open => fixed |
2009-10-02 10:59 | AHUser | Assigned To | => AHUser |
2009-10-03 13:13 | obones | Note Added: 0016225 | |
2009-10-03 13:13 | obones | Status | resolved => feedback |
2009-10-03 13:13 | obones | Resolution | fixed => reopened |
2009-10-03 13:21 | dcabale | Note Added: 0016226 | |
2009-10-03 14:25 | AHUser | Note Added: 0016228 | |
2009-10-03 14:25 | AHUser | Status | feedback => resolved |
2009-10-03 14:25 | AHUser | Resolution | reopened => fixed |