[ic] (Customer record creation): There was an error adding you to the customer table

Nikola Lazic nl at vpi.us
Tue Dec 6 21:26:33 UTC 2011


Using Interchange 5.4.0, when a user completes an order with a postal code
with fewer than 4 characters the order will be created in the database, but
the order file will not be created, the email will not be sent and the user
will get this error message:

(Customer record creation): There was an error adding you to the customer
table

Error.log contains these lines
111.111.111.111 EQxthXTt:111.111.111.111 - [06/December/2011:12:31:11 -0400]
vpi /cgi-bin/store/ord/finalize.html Safe: Auto-create of user failed.
Reason: Must enter at least 4 characters for password.
> 
>  die errmsg("Auto-create of user failed. Reason: %s", $Session->{failure})

> 
111.111.111.111 EQxthXTt:111.111.111.111 - [06/December/2011:12:31:13 -0400]
vpi /cgi-bin/store/ord/finalize.html Route log failed.
111.111.111.111 EQxthXTt:111.111.111.111 - [06/December/2011:12:31:13 -0400]
vpi /cgi-bin/store/ord/finalize.html ERRORS on ORDER :
> Error during creation of order routing log:
> Route log failed. at /usr/local/interchange/lib/Vend/Order.pm line 1835.
>

I confirmed that the default password minimum length is 4 characters:

/usr/local/interchange/lib/Vend/UserDB.pm Line 274
PASSMINLEN	=> $options{passminlen}	|| 4,

The cause of the error is catalogs/store/etc/log_transaction because it uses
the ZIP Code as the password and the default minimum length of the password
is 4 characters.

Line 122 - 127
[userdb
	function=new_account
		assign_username=1
		password='[value zip]'
		verify='[value zip]'
]

Line 151 - 157
[tmp hide_status][userdb
	function=new_account
	no-login=1
	assign-username=1
	password='[value zip]'
	verify='[value zip]'
][/tmp]

To fix I've added 4 characters before [value zip] in all four instances,
forcing the password to be 4 characters regardless of the length of the Zip
Code:

Modified Line 122 - 127
[userdb
	function=new_account
		assign_username=1
		password='auto[value zip]'
		verify='auto[value zip]'
]

Modified Line 151 - 157
[tmp hide_status][userdb
	function=new_account
	no-login=1
	assign-username=1
	password='auto[value zip]'
	verify='auto[value zip]'
][/tmp]

Nikola Lazic





More information about the interchange-users mailing list