News:

AbanteCart v1.4.4 is released.

Main Menu

Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Nimitz1061

#136
I have isolated the nature of the problem more specifically.

Double checked the encapsulation.  The only difference in the results was that live imports started to return a somewhat vague error message to the effect that the import file was either empty or corrupted.

I knew the file was not empty, so I went back to file contents.

While the test imports had not indicated any problems with content, the file I'm using DID include additional columns not related to Abantecart database tables and columns.  Removing SOME of these columns resulted in changes in the queries reported to be generated by the test routines, and a (somewhat) successful product import. 

The queries generated now look like:

INSERT INTO `products` SET `product_id` = '', `model` = 'NC28949-1', `weight` = '1', `weight_class_id` = '5', `date_available` = '4/1/2004 13:28', `date_added` = '4/1/2004 13:28', `quantity` = '99999', `price` = '0', `manufacturer_id` = '3', `tax_class_id` = '1', `status` = '0'

INSERT INTO `resource_map` SET `object_name` = 'products', `object_id` = 'new_id', `resource_id` = '', `default` = '', `sort_order` = '', `created` = '', `updated` = ''

INSERT INTO `resource_library` SET `resource_id` = 'new_id', `type_id` = '1', `created` = '', `updated` = ''

INSERT INTO `resource_descriptions` SET `resource_id` = 'new_id', `language_id` = '1', `name` = 'NC28949-1.jpg', `title` = '', `description` = '', `resource_path` = 'NC28949-1.jpg', `resource_code` = '', `created` = '', `updated` = ''

INSERT INTO `product_descriptions` SET `product_id` = 'new_id', `language_id` = '1', `name` = 'Guardian Economy Transfer Seat', `description` = 'The Guardian® Economy Transfer Bench is made of molded-plastic and has a nonslip textured surface and drainage hole.  The backrest can be attached on either side. Seat height on this shower transfer bench adjusts from 16 ½" to 21 ½". Thie tub transfer bench fit tubs from 11" to 17" deep. Optional legs with suction cups are availabe on this bath transfer chair to increase stability. Bath transfer bench supports up to 300 lbs.', `meta_description` = 'Economy transfer seats at Life Solutions Plus. Your source for shower transfer benches, bath transfer benches, shower chairs, bath seats.', `meta_keywords` = 'bath transfer bench, shower transfer bench, economy transfer seat, transfer seat, shower chair, bath seat, shower stool, Guardian economy transfer seat, bath tub transfer bench, tub transfer bench, bath chair handicap'


Note the new insert for products_description table, and the absence of attempts to insert data to missing fields in the resource_map table.

The total number of queries generated increased from 360 to 452.   The live import was successful to the extent that product data WAS imported.  Products were not assigned to the default store, or to categories.  This is not unexpected, given that neither was included in the file set. (Note:  I've yet to figure out how to assign the product to a store, though I do have an idea for how category assignment should work which I will test in the next few days.)

What was unexpected was that the resource column assignments which I thought would assign a product image file name to the product failed to do so.

So, some progress is being made.   Strangely, some foreign column headings (and content!) remained in the file.  Content included text and numbers.  The columns deleted contained only file names, including some with sub-directories  in the paths.  This may be a good clue.....


David
#137
Opened my file with Open Office SCalc, resaved.  This is encapsulated in double quotes.

Result:

Data is empty or corrupted.

File is not empty, (still contains 99K of data). 


The original tab delimited file still reports no errors when ran in test mode:

Test run completed. Total SQL queries: 360.  Show details
and
Total loaded: 360. Updated: 0. Created: 360. Errors: 0

are the results.

Detail wise the queries reported as being generated for a single product are:


INSERT INTO `products` SET `product_id` = '', `model` = 'PNC28708', `weight` = '1', `weight_class_id` = '5', `date_available` = '4/1/2004 0:00', `date_added` = '4/1/2004 13:28', `quantity` = '99999', `price` = '32.95', `manufacturer_id` = '3', `tax_class_id` = '1', `status` = '1'

INSERT INTO `resource_map` SET `object_name` = 'products', `object_id` = 'new_id', `resource_id` = '', `default` = '', `sort_order` = '', `created` = '', `updated` = '', `name` = 'Toilet Tissue Aid', `description` = 'This toilet tissue aid is a simple solution for people who need an extended reach. The spring clamp on this toilet tissue holder easily opens to release tissue paper. This handy toileting aid measures 10" long. The vertical handle and horizontal clamp both measure 6" long. This bathroom aid is ideal for persons who are disabled, obese or are small people(dwarfism). Use with No Rinse Peri-Wash for added personal hygiene.', `meta_description` = 'Toilet tissue aides at Life Solutions Plus. Your source for toilet tissue holders, bathroom aides, toileting aides, toilet aides.', `meta_keywords` = 'toilet tissue aid, toilet tissue holder, bathroom aid, toileting aid, toilet aid, ass wipe, butt wipe'

INSERT INTO `resource_library` SET `resource_id` = 'new_id', `type_id` = '1', `created` = '', `updated` = ''

INSERT INTO `resource_descriptions` SET `resource_id` = 'new_id', `language_id` = '1', `name` = 'Toilet-Tissue-Aid-Paper-S.jpg', `title` = '', `description` = '', `resource_path` = 'Toilet-Tissue-Aid-Paper-S.jpg', `resource_code` = '', `created` = '', `updated` = ''



I have difficulty envisioning this as an encapsulation problem.

Note the resource map table query:

INSERT INTO `resource_map` SET `object_name` = 'products', `object_id` = 'new_id', `resource_id` = '', `default` = '', `sort_order` = '', `created` = '', `updated` = '', `name` = 'Toilet Tissue Aid', `description` = 'This toilet tissue aid is a simple solution for people who need an extended reach. The spring clamp on this toilet tissue holder easily opens to release tissue paper. This handy toileting aid measures 10" long. The vertical handle and horizontal clamp both measure 6" long. This bathroom aid is ideal for persons who are disabled, obese or are small people(dwarfism). Use with No Rinse Peri-Wash for added personal hygiene.', `meta_description` = 'Toilet tissue aides at Life Solutions Plus. Your source for toilet tissue holders, bathroom aides, toileting aides, toilet aides.', `meta_keywords` = 'toilet tissue aid, toilet tissue holder, bathroom aid, toileting aid, toilet aid, ass wipe, butt wipe'

This contains data that appears to be consistent with the use for which it is labeled in the file. 

Note also the fields reported, compared to the actual structure of the table involved:


--
-- Table structure for table `resource_map`
--

CREATE TABLE IF NOT EXISTS `resource_map` (
  `resource_id` int(11) DEFAULT NULL,
  `object_name` varchar(40) COLLATE utf8_bin NOT NULL,
  `object_id` int(11) NOT NULL,
  `default` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0-no, 1-Yes',
  `sort_order` int(3) NOT NULL DEFAULT '0',
  `created` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
  `updated` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  UNIQUE KEY `resource_map_index` (`resource_id`,`object_name`,`object_id`),
  KEY `group_id` (`resource_id`,`object_name`,`object_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin;


This is clearly a mistake in the name of the table used in the previous query.

Where the actual resource map should be derived from I don't know.  But there are no name, description, meta_description or meta keywords fields in the resource_map table.

So, this should not work for the developer.

My working conclusion at present is that the code distributed and the code being tested by the developer are not the same.

David
#138
Umm, I think the links were already clear enough.  I was asking if the topic could be pinned so that it would stay at the top of the listing..

David
#139
The file used is a modified Easy Populate file generated from a CRE Loaded B2B cart.

It was processed using Excel, saved to text (Tab Delimited) using no changes from the default settings.

David
#140
I posted details to the issue tracker.

Import system does not allow selecting what you are importing..

David
#141
Could this be pinned to make it easier to find??

Thanks.

David
#142
While tests are successful, actual imports are not.

Each product line generates a MySQL error 1054:  unknown field 'name'. 

Apparently the importer fails to separate product elements into the appropriate inserts, and attempts to insert fields destined for the products_description table into the products table.

David
#143
I'm now getting rather successful TEST imports on products.  Not sure just how indicative of eventual success this would be, given the lack of any error message about missing store relationship assignments in the manufacturer file.  But, seems promising so far. 

I'm a bit concerned about the number of fields required to handle one image, and the apparent defaulting of image titles and descriptions to be the same as the product name / description.  This MIGHT lead to some duplicate content issues down the road.

The presence of resource name and resource PATH fields raises the question of which should be available during import and what will be necessary to generate the other....

David
#144
I have accomplished my first import to the cart - manufacturer entries.

There was a problem.

Manually created entries in this system have two table entries.  One in the manufacturers table, one in the manufacturers_to_stores table.  The import creates no entries in this table even when the columns for that tables entries exist..

The resulting entries do not work in the cart, as they have no store assignments..

David
#145
Craig,

The dev team has acknowledged the flaw as I identified it and will update the code..

David
#146
Opinions / Re: Relational Database and transactions
July 06, 2012, 10:53:43 AM
Quote from: abantecart on March 09, 2012, 11:58:50 AM
We have started to create relational and transactional InnoDB database at first, but researched showed that hosting mostly support MyISAM. This would be a problem.

We will watch future direction.

I would suspect that your research is flawed in some way.

InnoDB has been the default engine since at least MySQL 5.0 was released, thus transactional support should be available to any host using up to date installations.  Anyone who is not should not be considered a viable host for any ecommerce applications.

Transactions should be placed in use as soon as it is practical to do so.

David


#147
Opinions / Re: Undo feature
July 06, 2012, 10:43:22 AM
Not important at all.

What would be helpful would be an interstitial "are you sure" page which could help avoid committing a change without review of submitted data.

This offers two benefits.  First, avoiding inadvertent deletions and updates.  Then, in the event of some sort of security flaw such as the widespread PHP_SELF based injection flaws in a certain famous shopping cart many of us have worked with in the past, it can stop those flaws dead as a second line of defense...

David
#148
Opinions / Re: Whitelable Configuration Setting
July 06, 2012, 10:36:59 AM
I'm not sure it is important at all.  I would say it may be important to not display any information on which cart is being used on any pages which do not require the user to be logged in for access....

David
#149
I have found 2 issues which may impact this.

1.  Reference to DIR_SYSTEM has been made in a file included in init.php BEFORE definition of DIR_SYSTEM occurs.
2. The PHP system() function is used in three places in the cart, including the package manager.  Not all servers allow the use of the system function.  In fact, some servers periodically change which functions are allowed for security reasons. 

The upshot of this is, the temporary fix I mentioned above should be safe.  Some users may need to replace the system() function calls with calls to exec() or other functions in that family in order to get the functionality provided.  I'm not fully clear at this point on just what that is, but it would appear that this includes OR possibly includes backup/restore, data import/export and package management functions possibly including upgrades.

David
#150
Support / Re: Manual Update Instructions ??
July 05, 2012, 02:19:36 PM
It is NOT missing.

A developer added a new usage of DIR_SYSTEM in the lib/error.php file during the 1.0.3 development cycle.

lib/error.php is included into init.php BEFORE DIR_SYSTEM is defined.  Every new install or upgrade should now have this problem.



David

Forum Rules Code of conduct
AbanteCart.com 2010 -
Powered by SMFPacks Social Login Mod