Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

PAYPAL IPN: 1062 - Duplicate entry '0' for key 1


4QMobiles

Recommended Posts

Posted

hi there im having some trouble installing the paypal ipn module, everything seemed fine but once the customer goes through checkout right to the end they get this message:-

 

 

1062 - Duplicate entry '0' for key 1

 

insert into orders (customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, orders_status, last_modified, currency, currency_value, date_purchased) values ('4', 'omar test2', '', '123 test st', 'test road', 'tester', 'll1 2bh', '', 'United Kingdom', '123456789', '[email protected]', '1', 'omar test2', '', '123 test st', 'test road', 'tester', 'll1 2bh', '', 'United Kingdom', '1', 'omar test2', '', '123 test st', 'test road', 'tester', 'll1 2bh', '', 'United Kingdom', '1', 'PayPal', '', '', '', '', '1', now(), 'GBP', '1.00000000', now())

 

 

i would be extremely grateful for any help PUHLEAAAAAASE :)

thanks in advance, i love this community :thumbsup:

Posted

Make sure that the IPN you are using is named osCommerce Pay Pal IPN, the one officially supported by osCommerce Team Members. You'll find it around page 14 of Payment Modules in Contributions.

 

Vger

Posted

i tried the official one but for some reason i had a problem with this so sort of looked around this one seemed fine and seems to be working except this error. saying that im sure i got the same error with the official one.... so not quite sure were the problem lays :(

 

nothing that i can do with this one? PayPal_Shopping_Cart_IPN v3.0 i believe

 

thanks for the reply

Posted
i tried the official one but for some reason i had a problem with this so sort of looked around this one seemed fine and seems to be working except this error. saying that im sure i got the same error with the official one.... so not quite sure were the problem lays :(

 

nothing that i can do with this one? PayPal_Shopping_Cart_IPN v3.0 i believe

 

thanks for the reply

drop the orders table and create a new one.

That should do for you.

 

Satish Mantri(enSys)

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Posted

thanks for the reply i tried that and still no joy im afraid :(

 

what i did install was the random order module thing so that each order is given a random number instead of sequence... might that be the reason? and if so how can i get around that? or would i need to uninstall the random number module?

 

thanks again

Omar

Posted

If installing that contribution caused the error to appear then uninstall it. It's not exactly an 'essential - must have' type of Contribution.

 

Vger

Posted

hi there thanks for the reply, i see what you are saying but what im asking is, is that likely to be the cause? is there a link between getting that error message and the random contrib?

Posted
is there a link between getting that error message and the random contrib?

 

I could only tell you that by going through all of the code in that contribution, and then checking the code in your website to make sure you applied it correctly.

 

I try to be helpful - but not that helpful!

 

Vger

Posted

ok i uninstalled the random numbers mod, and now get this error

 

 

1054 - Unknown column 'payment_id' in 'field list'

 

select payment_id from orders where orders_id ='0'

 

[TEP STOP]

 

 

funny thing is when i first run the script it all goes through fine but when i start going back and trying it again i get this error... so it worked sorta :)

 

 

im sure the problem is very simple now but would be grateful for the help as im gonna start pulling my hair out.

Posted
ok i uninstalled the random numbers mod, and now get this error

1054 - Unknown column 'payment_id' in 'field list'

 

select payment_id from orders where orders_id ='0'

 

[TEP STOP]

funny thing is when i first run the script it all goes through fine but when i start going back and trying it again i get this error... so it worked sorta :)

im sure the problem is very simple now but would be grateful for the help as im gonna start pulling my hair out.

Hi,

when you uninstalled a field too was dropped so the bug.

Or while uninstalling some code still was not removed.

So first check is the filed that is missing related tot he module that you uninstalled if so then you forgot to comment are revert to all the code that was to be.

 

Satish Mantri

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Posted

hi Satish thank you for your reply, the random order number is a ver simple mod, its more of a coding mod rather than replacing or adding files, so there were no fields changed in the database during this.

Posted

There is no such field as payment_id in osCommerce. However, there is such a field in CRE Loaded - which is nothing to do with osCommerce. So you've had people trying to help you on this forum, while you were wasting their time with queries about a different shopping cart.

 

Angry? You Bet!

 

Try the CRE loaded forum next time!

 

Vger

Posted

its not cre loaded... so count backwards from 10 and calm down, i have no intention of wasting peoples time, like i wouldnt want people to waste mine, i have used the cre loaded one which was installed by my previous host, but this is oscommerce 2.2 ml2, im sure cre loaded had paypal ipn installed anyway eh? so wouldnt of asked for help in the first place. anyways thanks and sorry i spoiled your evening. :P

Posted

I realised after I posted that CRE loaded uses the old Pay Pal IPN by Greg Baboolean that is still available for download from Contributions here. So, apologies, got that wrong.

 

You said in one of your early posts that you had tried installing a Pay Pal IPN module, and obviously it was this old version, and from the error you are getting parts of it are installed but not the sql changes that came with it. To complete the installation you'd need to run the sql file to add the extra tables - but my advice would be to work in reverse and uninstall this old IPN module. It's been my experience that this module stopped working correctly in osCommerce some time ago.

 

Vger

Posted

thanks for the reply, and my apologies to. i think whats happened is during my many attempts to install modules and especially this one i may have not correctly uninstalled ones that didnt work hence this field may of got left behind, this has pushed me now to start a 2nd site and get this up and running and stable, whilst letting the old one run for the minute, so times of the essense, in brief i have now got a fresh copy so nothing else is installed, files intact etc... this is the mod i used to install and updated the sql database to.

 

http://www.oscommerce.com/community/contri...arch,paypal+ipn

 

PayPal_Shopping_Cart_IPN_v3.0a

 

i see theres so many versions and if you say this stopped working then that would explain this new fault i get :)

 

in the admin i goto the new option PAYPAL IPN were i believe paypal orders will be located and i get this error

 

<body marginwidth="0" marginheight="0" top margin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF" onload="

Fatal error: Cannot use object of type PayPal_Page as array in /home/alleyes/public_html/trade2/includes/modules/payment/paypal/templates/osC_Admin.tpl.php on line 27

 

im more than happy to just leave this and use the official one but not sure which it is and if so which version to use as they seem to update regularly. and not sure if all mods update for the better or not.

 

i appreciate your help either way in this matter, just a case of being pointed in the right direction, i know how to install the mods and follow the instructions but im left pulling my hair when i get an error.

Posted

I'm afraid that the module you've installed is still not the best one for the job. I know this community is Open Source, but we only need one 'working' Pay Pal module so I do wish they'd delete the rest!

 

The one you want is here (officially supported by osCommerce Team Members):

 

http://www.oscommerce.com/community/contri...ns,2679/page,14

 

It has several advantages:

 

1. It works.

2. It's all new files and one new folder, so there's no need to edit anything else, and no entries to be added to the database. This means you can use the 'Remove' button in your osC admin panel for the one you have installed. It won't remove the files but it'll be non-operational so won't generate any errors.

 

Vger

  • 3 weeks later...
Posted
I'm afraid that the module you've installed is still not the best one for the job. I know this community is Open Source, but we only need one 'working' Pay Pal module so I do wish they'd delete the rest!

 

The one you want is here (officially supported by osCommerce Team Members):

 

http://www.oscommerce.com/community/contri...ns,2679/page,14

 

It has several advantages:

 

1. It works.

2. It's all new files and one new folder, so there's no need to edit anything else, and no entries to be added to the database. This means you can use the 'Remove' button in your osC admin panel for the one you have installed. It won't remove the files but it'll be non-operational so won't generate any errors.

 

Vger

 

I'm currently using the Official PayPal IPN, but my orders are not getting marked as "Processing" after they have been verified. I'm using aggregated carts, no encryption, and IPN set to 'on' and pointing to the /ext/modules/payment/paypal/ipn.php

 

Any help you can give would be greatly appreciated.

Posted

having difficulty understanding all the Configuration Parameters for for PayPal IPN Payment Module v1.1 when following the install instructions...

 

also, what is the Return URL, per PayPal "Enter the URL that will be used to redirect your customers upon payment completion. This URL must meet the guidelines detailed below."

Posted
having difficulty understanding all the Configuration Parameters for for PayPal IPN Payment Module v1.1 when following the install instructions...

 

also, what is the Return URL, per PayPal "Enter the URL that will be used to redirect your customers upon payment completion. This URL must meet the guidelines detailed below."

 

think i found my own answer http://www.oscommerce.com/forums/index.php?sho...5&hl=ipn+module

the return URL should be set to httpS://yourdomain.com/catalog/ipn.php

 

currently the ipn.php file is located \catalog\ext\modules\payment\paypal_ipn

 

the problem is i don't have an IPN.php so hopefully i can find more on what needs to be in this file...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...