Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsStoreStoreCoupon causes critical errorCoupon causes critical error
Previous
 
Next
New Post
5/4/2013 11:33 AM
 

Hi Giles,

Need your help on this one. If you set up a coupon as Single Use, then when the user enters it during checkout you usually get the following error:

"A critical error has occurred. An unexpected error has occurred."

We went through a number of different permutations in testing the coupons and on one occassion got this error message:

"A critical error has occurred.The stored procedure 'dbo.Store_Orders_CountCouponUsage' doesn't exist."

This is important to our customer who wants to send out some special one time use discounts to specific clients in the media. One thing that wasn't clear is if the one time use is per customer or if it can only be used once regardless of who uses it. We had hoped to figure this out during testing.

Giles, the customer really likes the product as its a great fit for their specific product line.

Cheers,
Larry

 
New Post
5/4/2013 11:51 AM
 
One other interesting note when this error occurs. The user cannot logout. The only way to get out of it is to close the session, clear the cache exit IE9 and then restart IE9. Haven't tried it with another browser.

Cheers,
Larry
 
New Post
12/4/2013 1:13 PM
 

The problem is inside 03.01.04.SqlDataProvider there are missing one "GO" after

CREATE PROCEDURE {databaseOwner}[{objectQualifier}Store_Orders_UpdateOrderDetails]

so this automatically apply

IF EXISTS (SELECT * FROM {databaseOwner}[sysobjects] WHERE id = object_id(N'{databaseOwner}[{objectQualifier}Store_Orders_CountCouponUsage]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)

DROP PROCEDURE {databaseOwner}[{objectQualifier}Store_Orders_CountCouponUsage]

GO

and drop the procedure.

 

Solution:

Go to procedure "Store_Orders_UpdateOrderDetails" in your database and delete  from the bottom of it

IF EXISTS (SELECT * FROM {databaseOwner}[sysobjects] WHERE id = object_id(N'{databaseOwner}[{objectQualifier}Store_Orders_CountCouponUsage]') and OBJECTPROPERTY(id, N'IsProcedure') = 1

DROP PROCEDURE {databaseOwner}[{objectQualifier}Store_Orders_CountCouponUsage]

after that re-create the "Store_Orders_CountCouponUsage" procedure like below:

CREATE PROCEDURE [dbo].[dnn_Store_Orders_CountCouponUsage]

@PortalID int,

@UserID int,

@CouponID int,

@OrderID int

AS

SET NOCOUNT ON

SELECT COUNT(*) FROM dbo.dnn_Store_Orders o

WHERE o.PortalID = @PortalID AND o.UserID = @UserID AND o.CouponID = @CouponID AND o.OrderID <> @OrderID AND o.OrderIsPlaced = 1

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsStoreStoreCoupon causes critical errorCoupon causes critical error


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out