Zen Cart Logo
Forums / All Other Contributions/Addons / Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Views: 83,541

Results 241 to 260 of 318
22 Mar 2011, 18:57
#241
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

If you plan to change your field name, make sure you retrace all the steps and change it everywhere - throughout the files, in the database. If you're trying to add a new field, leave the existing field intact and follow the instructions toward the beginning of this thread, for adding a new field.

22 Mar 2011, 20:42
#242
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Okay, so how do I change it in the DB? I thought the steps in the first post did that?

22 Mar 2011, 20:54
#243
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Ok, on a second more detailed look at your question, I was too quick to answer.

zc v2.39 There is no such version of zen cart, do you mean 1.3.9? What version of Easy Populate are you running?

Just tried to replace v_products_weight with v_products_shipping_code You're not really supposed to be replacing existing variables - this thread shows you how to ADD NEW product fields.

#144 - Table './seriouso_zc1/zc_products' is marked as crashed and last (automatic?) repair failed Boy, that's a scary error. Try a full backup of your database. Then run repair/optimize from phpmyadmin. you may want to contact your host to repair the database for you (or restore to yesterday's version).

And again, start a fresh process on adding a new field and CAREFULLY follow the instructions.

22 Mar 2011, 21:07
#244
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

sorry, chubby fingers.
v1.39h.

My host reloaded my DB and I've gone through the easypopulate.php file half a dozen times and replaced all instances of v_products_weight with v_products_shipping_code, all instances of p.products_weight with p.products_shipping_code, basically everytime weight is shown I replaced it with shipping_codes.

The DB still shows v_products_weight and not v_products_shipping_code.

What

22 Mar 2011, 21:10
#245
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

As the instructions specify, you are not supposed to be REPLACING weight, you are supposed to COPY and CHANGE the new variable. You are using weight only as a reference to ADD NEW field, not to change the existing field.

22 Mar 2011, 21:15
#246
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

########...

So I need to change everything back and then ADD v_products_shipping_code and p.products_shipping_codes?

22 Mar 2011, 21:17
#247
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Yes, you should start fresh and ADD your new field following the instructions very carefully.

Also, make sure you watch the variable name... products_shipping_code and products_shipping_code**(s)** are different.

22 Mar 2011, 21:18
#248
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

:cry::cry::cry:

22 Mar 2011, 21:22
#249
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

okay before I screw this up again.

My zc_products does not contain the field v_products_shipping_code.

Will changing the EasyPopulate.php file add it to the DB?

22 Mar 2011, 21:48
#250
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Serious:

Will changing the EasyPopulate.php file add it to the DB?

The answer is NO.

So I'm kinda stumped. Do I just insert a line in the DB?
If so, what do I enter into the Type, Collation, Attributes, Null, Default, Extra, fields?

22 Mar 2011, 23:35
#251
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Anyone have any thoughts?

23 Mar 2011, 00:24
#252
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

You have to add the row v_products_shipping_code to your database otherwise the code is referencing a non-existent row in the table and creates errors. The EP file DOES NOT add a new row to the database, you must add it manually.

You can replace the weight but if you need to use product weight in your cart I don't recommend replacing it.

I showed you in a previous post how to insert new rows into the database. Follow those directions and add the new row and then you should no longer have problems with EP.

23 Mar 2011, 00:32
#253
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

That's what I thought the answer was going to be, but I'm still clueless as to what goes into the Type, Collation, Attributes, Null, Default, Extra, fields.

23 Mar 2011, 00:40
#254
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

I'm about ready to pull my damn hair out!!

How do you insert a new field?
Selecting "Insert" just inserts a row but won't let me add a Field.

ARGH!!!!!!!!!!!!

23 Mar 2011, 00:49
#255
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

So I tried just editing the field products_weight and made it products_shipper_code.
The result was the following on the right side of my website.

1054 Unknown column 'p.products_weight' in 'field list'
in:
[select p.products_id, p.master_categories_id, p.products_status, pd.products_name, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_tax_class_id, p.products_quantity_order_min, p.products_quantity_order_units, p.product_is_free, p.products_priced_by_attribute, p.products_discount_type, p.products_discount_type_from from zc_products p, zc_products_description pd where p.products_id = '11048' and pd.products_id = p.products_id and pd.language_id = '1']

23 Mar 2011, 01:08
#256
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Serious:

That's what I thought the answer was going to be, but I'm still clueless as to what goes into the Type, Collation, Attributes, Null, Default, Extra, fields.

Don't worry about that. If you follow my instructions it will work. Have you tried it?

23 Mar 2011, 01:09
#257
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

Alright lankeeyankee,
I read the post you linked too. This is what I want to add:
*ALTER TABLE products ADD product_shipping_code CHAR(1) NOT NULL DEFAULT 'A' AFTER products_price;
*

First attempt netted a sytax error so I tried this:

*ALTER TABLE **zc_**products ADD product_shipping_code CHAR(1) NOT NULL DEFAULT 'A' AFTER products_price;
*
YES!!! That worked and added product_shipping_code to zc_products.

I reloaded my tab Delimited Txt file.
Went to my site and attempet to complete a checkout process. After selecting "Go to checkout, the following message appears.

1054 Unknown column 'v_products_shipping_code' in 'field list'
in:
[ SELECT v_products_shipping_code FROM zc_products WHERE products_id = '11048';]

23 Mar 2011, 01:10
#258
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

You're welcome to try it yourself if you like.

https://www.seriousoffroadproducts.com

23 Mar 2011, 01:18
#259
serious avatar

serious

Totally Zenned

Join Date:
Feb 2011
Posts:
686
Plugin Contributions:
0

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

If it helps, I'm hapy to email you the easypopulate.php file that i edited to add v_products_shipping_code

23 Mar 2011, 02:14
#260
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

Re: Here's a quick tutorial on how to add fields to easypopulate v1.2.5.4 or 1.2.5.5

It appears that the altering of the zc_products table didn't go correctly. Can you paste in a screenshot from phpmyadmin of the zc_products table with the Structure tab selected?