Miva Merchant 4 Module FAQs » Category Import (VIK_CATIMPT)
The format for the flatfile is very simple:
categorycode|categoryname|parentcode|active
In this example, we have used the pipe character "|" a the delimiter (the character that separates the fields from each other). You can use tabs, commas, or anything else you like but we recommend using the pipe. For whatever delimiter you use though, you need to make sure that that particular character does not appear in your data itself.
For example, this would NOT work correctly:
category123|This is my |new| category name!|categoryxyz|1
The reason this would not work is that the pipe characters on each side of the word "new" will confuse the import, making it think that there are six fields to be imported, when there are only four. This problem is especially compounded if you have a tab delimited file as the tabs often cannot be seen--they look just like spaces. Thus, it's best to use the pipe character, which is a seldom used symbol.
In the above example, you can see that we used a "1" for the Active field. This is correct, or you can also use YES or TRUE.
Here is an example of a working flatfile:
category123|Category 123|Category ABC|1
category456|Category 456|Category ABC|1
category789|Category 789|Category ABC|1
categoryxyz|Category xyz||1
In this example, you'll notice that categoryxyz does not have any entry in the parent field. Leaving this field blank indicates that categoryxyz does not have a parent, it is a major category.
How to Make a Flatfile:
A flatfile is simply a text file, so pretty much any database or spreadsheet program can be used for creating the flatfile. You can use Excel for this, but it does have some quirks. Excel will generally put quote marks around some text so you may need to open any flatfiles exported from Excel to remove the quote marks.
Most Recent FAQ Entries:
Top 10
Importing Categories From a Flatfile
What is a flatfile and how do I use it?
The format for the flatfile is very simple:
categorycode|categoryname|parentcode|active
In this example, we have used the pipe character "|" a the delimiter (the character that separates the fields from each other). You can use tabs, commas, or anything else you like but we recommend using the pipe. For whatever delimiter you use though, you need to make sure that that particular character does not appear in your data itself.
For example, this would NOT work correctly:
category123|This is my |new| category name!|categoryxyz|1
The reason this would not work is that the pipe characters on each side of the word "new" will confuse the import, making it think that there are six fields to be imported, when there are only four. This problem is especially compounded if you have a tab delimited file as the tabs often cannot be seen--they look just like spaces. Thus, it's best to use the pipe character, which is a seldom used symbol.
In the above example, you can see that we used a "1" for the Active field. This is correct, or you can also use YES or TRUE.
Here is an example of a working flatfile:
category123|Category 123|Category ABC|1
category456|Category 456|Category ABC|1
category789|Category 789|Category ABC|1
categoryxyz|Category xyz||1
In this example, you'll notice that categoryxyz does not have any entry in the parent field. Leaving this field blank indicates that categoryxyz does not have a parent, it is a major category.
How to Make a Flatfile:
A flatfile is simply a text file, so pretty much any database or spreadsheet program can be used for creating the flatfile. You can use Excel for this, but it does have some quirks. Excel will generally put quote marks around some text so you may need to open any flatfiles exported from Excel to remove the quote marks.
Last update: 2003-08-12 21:30
Author: Support
Revision: 1.0
You cannot comment on this entry
Most Recent FAQ Entries: 
- I have the module configured to add the key ... (2008-08-13 14:50)
- What is the format for the htaccess file if ... (2008-08-12 14:50)
- Is there any way to look up a customer's ... (2008-08-06 18:04)
- I am looking for a module that will allow ... (2008-08-06 18:00)
- Is it possible to display a link in Phone ... (2008-08-06 12:05)
Top 10 
- 2754 views:
Adding Tokens to Evaluate Expressions - 2698 views:
Is there a way to "Limit" the number of ... - 2654 views:
Why won't you call me for technical support? I ... - 2549 views:
Are license keys valid for more than one store? ... - 2447 views:
I'm trying to enter a license key and get ... - 2425 views:
How do I install a module? - 2286 views:
How do I check for a module upgrade? - 2255 views:
How can display and change the parameters of an ... - 2097 views:
The total on my checkout pages are not correct. ... - 1932 views:
I have select and radio type attributes in my ...
















