say i have a field that lists car year, car manufacturer, and car model.....is it possible to parse this into 3 different outputs? considering they will be different lengths?
now the only problem is that if data runs through that reads 2003 Pontiac Grand Am........i get 2003 in a column.....Pontiac Grand in a column, and then Am in a column in stead of 2003,pontiac, grand am
futbwal15,
how many records you have in that table (fileinfo)?
Better add 3 other fields (and please don't make them TEXT) and keep there the year, Manufacturer and model. You could use the examples here to split the custom1 field to other fields and then remove that field (custom1). Of course you must change all program logic in your FrontEnd, but this is ONE-time job and that will makes you life much easier that now.
Borislav Borissov
VFP9 SP1, SQL Server 2000/2005.
MVP VFP
Personally, at this point in your data, I would probably create a new table called CarManufacturer. Put all of the car makers in that table. Then create three new columns in your original table (ModelYear, CarMaker, CarModel). Copy the year to the new ModelYear column. Then use the CarManufacturer table to compare with the rest of the string and move that value to CarMaker. Then move what is left to the CarModel table. Once you've split up the current string into its three parts and matching columns, drop the CarManufacturer table.
(You could also keep the CarManufacturer table and link it to the original table via Primary/Foreign key relationship).
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.