Zen Cart Logo
Forums / General Questions / VBA Code to lookup Attribute information from MySQL tables

VBA Code to lookup Attribute information from MySQL tables

Locked

Views: 1,939

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
8 Jun 2008, 1:58 AM
#1
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

VBA Code to lookup Attribute information from MySQL tables

Hi, I've been writing some Microsoft Excel VBA to retrieve information on my orders. I use the information to generate some custom emails.

Using the MySQL ODBC driver, and by creating an ADODB.Connection, I'm able to retrieve various order fields into cells in Excel. I'm having a problem though with attributes since they are stored in a BLOB field. I've been reading that I should be able to use a ADODB.Stream object to retrieve the BLOB data, but I'm not having a lot of luck (I'm not that fluent in VBA).

Has anyone ever done this or do you have any tips?

Thanks in advance.

8 Jun 2008, 1:23 PM
#2
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

Re: VBA Code to lookup Attribute information from MySQL tables

I have a follow-up question...

My issue would be resolved if the orders_products_attributes field was text. I'm running 1.3.7 and just read that in 1.3.8 the orders_products_attributes field was changed from BLOB to TEXT since it's not binary.

I'm wondering, could I just change the field to text in my 1.3.7 installation using MyPHPAdmin without ill effects, or would I have to modify some code?

Thanks.

8 Jun 2008, 6:31 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: VBA Code to lookup Attribute information from MySQL tables

Yes, you can just change it.

You should give some attention to the idea of upgrading, since a year's worth of bugfixes are included in the newer version ...

8 Jun 2008, 6:57 PM
#4
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

Re: VBA Code to lookup Attribute information from MySQL tables

Thanks, Dr. Byte!

I do want to upgrade, but I've made lots of modifications, so it's a project I need to plan and schedule for, and I'd rather do my back-office automation sooner rather than later.

Do you know off-hand, if I change the field now to text, will I run into issues when I do try to upgrade? Is there an upgrade script that will cause issues?

Thanks again.

8 Jun 2008, 7:08 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: VBA Code to lookup Attribute information from MySQL tables

No issues.