keepingbusy
Programmer
All
(Version 9)
I recently changed a field in a table from a character field (called column3) to a memo field. Part of the code used, copies the contents of the table into a CSV file:
As the data in table (products_description.dbf)field colum3 contains track listings, this can be more than 254 characters so a character field wont do.
The VisFox 9 help file states:
COPY TO Command........
FIELDS FieldList
Specifies which fields are copied to the new file. If you omit FIELDS FieldList, all fields are copied to the file. If the file you are creating is not a table, memo fields are not copied to the new file, even if memo field names are included in the field list.
As mentioned above, the data for column3 contains track listings that are more often than not, over 254 characters so a character field wont do.
How do I overcome this by getting the contents of the memo field into the CSV file?
Thank you
Lee
(Version 9)
I recently changed a field in a table from a character field (called column3) to a memo field. Part of the code used, copies the contents of the table into a CSV file:
Code:
lnLoop = CEILING(RECCOUNT()/70000)
FOR lnFor = 1 TO lnLoop
lcFileName = [products_description]+TRANSFORM(lnFor)+[.CSV]
COPY TO (lcFileName) NEXT mprod DELIMITED WITH CHARACTER ";"
NEXT
The VisFox 9 help file states:
COPY TO Command........
FIELDS FieldList
Specifies which fields are copied to the new file. If you omit FIELDS FieldList, all fields are copied to the file. If the file you are creating is not a table, memo fields are not copied to the new file, even if memo field names are included in the field list.
As mentioned above, the data for column3 contains track listings that are more often than not, over 254 characters so a character field wont do.
How do I overcome this by getting the contents of the memo field into the CSV file?
Thank you
Lee