• Toll-free  888-665-8637
  • International  +1 717-220-0012
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

jasonhick70
#1 Posted : Monday, September 10, 2007 10:35:44 AM(UTC)
jasonhick70

Rank: Member

Joined: 7/3/2007(UTC)
Posts: 79

Hi there,


Does anyone have any instructions or guidelines on how to add extra columns to the database?



We need to add 2 additional columns into the product table to support a "thumbnail" image type and an even shorter description or "teaser" for every product.



Has anyone done this or have any details on adding custom items into the db?



Any help would be most appreciated.... thanks :D



Regards,



Jason





Needapresent.com
bvuser
#2 Posted : Monday, September 10, 2007 11:53:57 AM(UTC)
bvuser

Rank: Member

Joined: 4/10/2006(UTC)
Posts: 462

Hi Jason,

Depending on how exactly you are planning on using them it can be a quick and easy db edit and a refactoring of several class files. The difference being how you are hoping to access the additional fields.

What I would suggest instead is simply adding a product property called "teaser" to your products and using the bvc api to use that product property for your teaser.

In regards to the thumbnails, you can use the same approach outlined above with a product property to specify the filename of the thumbnail or if your thumbnails are truely thumbnails (meaning smaller versions of the existing bv catalog images), you can use the .net api to resize them on the fly for the locations you need them in. Do note this later solution will take a few more cpu cycles and a bit of memory to implement, so it may or may not be a viable solution depending on the hardware you have available as well as your traffic patterns.
Netriplex Corporation<br />
blueacorn
#3 Posted : Monday, September 10, 2007 8:36:38 PM(UTC)
blueacorn

Rank: Member

Joined: 6/27/2007(UTC)
Posts: 63

Great tip caplink - is this how you would envision building something to accomodate the custom fields necessary for some of the shopping feeds? I haven't looked at the Froogle feed as an example yet but just thinking about it...
bvuser
#4 Posted : Monday, September 10, 2007 11:41:29 PM(UTC)
bvuser

Rank: Member

Joined: 4/10/2006(UTC)
Posts: 462

Depending on what type of settings you are referring to, yes. The froogle feed done by bvc basically makes a csv file of all data in the database, meaning any property that matches a field name google accepts is added into the feed. The shopping feed component we have written has a basic interface for selecting what properties to upload by product type and how to handle shipping data to be included in each feed for each product type. Some engines are very user/developer friendly like Shopping.com as the user can basically upload any feed and map the fields in their shopping.com account. Other engines tend to be a bit more picky.
Netriplex Corporation<br />
jasonhick70
#5 Posted : Tuesday, September 11, 2007 4:15:44 AM(UTC)
jasonhick70

Rank: Member

Joined: 7/3/2007(UTC)
Posts: 79

Hi there,


That sounds great, we use the "teaser" and the thumbnail to display in various sections on the homepage ("New Gifts" &amp; "Top 20") and all of the images have already been created so we wouldn't need to resize them on the fly, even though they are true thumbnails.



I've already added both columns to the db, but am not sure which class files i need to edit to get the values out of the db! For the moment i've managed to get the thumbnails displaying on the home page by building the &lt;img&gt; tag on the fly using the sku, as all our product images are named by sku which makes life a bit easier. But any pointers as how to proceed would be appreciated...



Regards,



Jason



Needapresent.com
bvuser
#6 Posted : Tuesday, September 11, 2007 9:13:48 AM(UTC)
bvuser

Rank: Member

Joined: 4/10/2006(UTC)
Posts: 462

Hi Jason,

My suggestion was to NOT add anything to the db and use some built in bvc functionality to work around the issue.

By adding those columns to the db you will need to modify stored procedures and pieces of the core and therefore will lose the ability to patch bvc5 in the future (without reapplying everything again at least). You could also just create a seperate sp that simply retrieved those values from the db and not change the class structure.

Personally, I would still recommend my previous suggestion over doing this.
Netriplex Corporation<br />
jasonhick70
#7 Posted : Tuesday, September 11, 2007 10:53:37 AM(UTC)
jasonhick70

Rank: Member

Joined: 7/3/2007(UTC)
Posts: 79

Okay,


I'm gonna be a bit dumb here (fairly new to BV! but certainly not as dumb as Britney :-o )



Do you mean go to Catalog &gt;&gt; Type Properties, create a new property, then create a new product type and add in the property I just created and set all my products to use this new product type? Phew!



Regards,



Jason
bvuser
#8 Posted : Tuesday, September 11, 2007 11:09:55 AM(UTC)
bvuser

Rank: Member

Joined: 4/10/2006(UTC)
Posts: 462

Yes, it isn't that hard, because one of the batch product edit options should be product type. If that doesn't exist for some reason, you can run a sql query in the db to change the product type of your whole catalog.
Netriplex Corporation<br />
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

©2024 Develisys. All rights reserved.
  • Toll-free  888-665-8637
  • International  +1 717-220-0012