Announcement

Collapse
No announcement yet.

Custom Variables - Data type error - expected an integer

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Custom Variables - Data type error - expected an integer

    I have tried adding a custom variable to my products to define the type of product (book, tshirt etc)

    Within the library I have defined type of custom variable as 'list of choices' and added text values under the values tab for this varaible.

    I am not using 'use parent' and it is settable at product level only.

    I have populated inital and top level value from the defined list of choices.

    I then performed an export, and changed some of the values for this custom field in the resultant spreadsheet, using copy and paste (ie the text values are using exising values as defined in the list of choices, not freshly typed text).

    On performing an import, I receive this error for each changed record

    Line 55: Data type error. The field Product Type was given comic new when it expected an integer.

    where 'product type' is the name of my custom variable and 'comic new' is a choice in list of choices.

    The values entered when defining the vaiable are all text, so why is it expecting an integer, and how do I work around this?

    Can you in fact edit custom variables using export/import, or is this not possible?

    Can't find any reference to this doing a search of the forum and AUG, so any ideas?

    Using Version 10

    Thanks in adavance

    #2
    You can certainly use a hierarchical import to update custom variables. I don't remember doing do so though with choices.

    Comment


      #3
      ProductType is a reserved name. Try a different name for your variable.
      Norman - www.drillpine.biz
      Edinburgh, U K / Bitez, Turkey

      Comment


        #4
        Hi Duncan
        Re: choices
        Maybe I'm using the wrong setting.
        What I want is to be able to set the custom variable within the product details, via a drop down list choice, rather than typing in text. Maybe I have set it up wrong. I have used the 'type' 'list of choices' in design | library | variables tab | basic definition | type. I am not after offering a list of choices to customers, just a list of possible entries to the custom variable in my product detail.

        Thanks Norman
        I actually used "Product Type" (with a space), which didn't report as a reserved name, but in light of what you have pointed out, it would be advisable to change it anyway.

        Any ideas why I am getting the 'expecting an integer' error on importing changes to this variable?

        Comment


          #5
          I've just given this a (quick) go. It works for me (v11) when I use a variable without spaces but not when the variable contains spaces, although even then I don't get any errors.

          Note that you can't just rename a variable, you need to delete it and then addd a new one.

          Comment


            #6
            OK, new custom variable name, and it works. I think Norman may have hit the nail squarely on the head, in that I was using a name that the system already uses, which caused the import to fail (even though it didn't actually tell me that the name I had chosen wasn't allowable!).
            thanks guys

            Comment

            Working...
            X