[ic] RE. Not able to add new items

Paul Jordan interchange-users@icdevgroup.org
Mon Jan 6 13:43:01 2003


>  RE. Jonathans post regarding NOT NULL db fields.
>
[snip]
>
> Thanks for the post, had a quick shot at sorting it out but still no joy.
> First off I had a look at the database structure, like you suggested
> (<catroot>/dbconf/mysql/products.mysql).  Now there are a few things here
> that I don't quite understand, although I might be wrong with this.
>
> Certain fields state that they should not have null values, however the
> default value that is specified is clearly NULL i.e. category=VARCHAR(64)
> NOT NULL DEFAULT ''.  Now I really don't understand this - but I
> went on as
> you suggested.  I went to the New Item section and started to add in a new
> item, ensuring that I filled in all the fields which required values.  My
> first problem was this, the db structure for products starts with:
>
> Database products KEY sku
> Database products COLUMN_DEF "sku=char(64) NOT NULL PRIMARY KEY"
> Database products COLUMN_DEF "description=VARCHAR(128) NOT NULL"
> Database products COLUMN_DEF "title=VARCHAR(128) DEFAULT '' NOT NULL"
> Database products INDEX title
> Database products COLUMN_DEF "template_page=VARCHAR(64)"
>
> - now when I go to New Item, I don't have any 'title' field
> displayed - thus
> no way of entering a value for this (Problem no.1).
>
> So not wanting to be put of I went to the table section of admin and
> displayed the products table as a spreadsheet - now I see the
> 'title' field
> as well as all the others that weren't displayed - however now I have a
> whole host of other fields that don't seem to be defined in the products
> table i.e. tax_category,dl_type, dl_location.  Now I don't know what these
> fields are or what they relate to, or for that matter, what value, if any
> they need.  Are these values defined in another table?  Why is the 'title'
> field not displayed on the New Item page, if it has to hold a value? And
> how, please, please can I get some products back into my system.
> Could the
> structure of my sql database be corrupted some how as a result of the
> upgrade.
>
> Sorry about the length of post, thanks in advance,
>
> Mike C


Hi Mike,

If you are a super-user then just click on "Item editor"... the red link at
top above the limit with search input on your item list page. This will
allow you to edit the meta display for your items and dislay of them in
ADMIN. NOTE the "Edit page" tab. Somehow your 'title' got hidden from you,
no biggie, just go into meta and put it back into "Fields to edit".

Also, I have not been following this too much, but have you checked your
error log? I went from 4.8.3 to 4.9.x and I seem to remember not being able
to add items. It came down to me needing to add a new column to table
mv_metadata, the column was named 'extended'.

I don't know why, but it cleard up alot of problems... so check if you have
that column in mv_metadata, if you don't, then add it.

HTH
Paul