Developer forum

Forum » Development » Parameter 'idList' contains no IDs - in assortments

Parameter 'idList' contains no IDs - in assortments

Dmitrij Jazel
Reply

Just started getting this error here:

Parameter 'idList' contains no IDs

Happens when customer logs in to /Admin and goes to Ecommerce > Assortments > Finds assortment > Edit assortment

Than as soon as he clicks on Attached products getting this error.

Server Error in '/' Application.


Parameter 'idList' contains no IDs

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.ArgumentException: Parameter 'idList' contains no IDs

Source Error: 

 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace: 
 

[ArgumentException: Parameter 'idList' contains no IDs]
   Dynamicweb.eCommerce.Products.Product.GetSqlConditionPartForIDs(String idList) +335
   Dynamicweb.eCommerce.Products.Product.GetProductsByProductIDs(String[] prodIDs, Boolean doRefactor, String languageID, Boolean bulkFill, Boolean useAssortments) +427
   Dynamicweb.Admin.eComBackend.EcomAssortmentEdit.GetProductData() +574
   Dynamicweb.Admin.eComBackend.EcomAssortmentEdit.HandleRequest() +2454
   Dynamicweb.Admin.eComBackend.EcomAssortmentEdit.Page_Load(Object sender, EventArgs e) +15
   System.Web.UI.Control.OnLoad(EventArgs e) +92
   System.Web.UI.Control.LoadRecursive() +54
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772

Replies

 
Dmitrij Jazel
Reply

Any idea why I am getting this error?

I checked, assortment has some data in it... So it is not empty in no way.

 

When you are trying to "attach product" and need to lookup products or groups - why this part would ever be different from how Dynamicweb retrieves normal product data from catalog overview in Admin.

Product overview works just fine, and Assortment does not. I guess they have different implementations, and it fails.

Though the goal is the same, just overview of the product list.

 
Morten Snedker
Reply
This post has been marked as an answer

Hi Dmitrij,

We've had a bug with "Variants removed from ecom are not cleared from Assortment" - which I think may cause this error.

Try pasting this to your SQL Server Management Studio:

SELECT        dbo.EcomAssortmentItems.AssortmentItemProductID, dbo.EcomAssortmentItems.AssortmentItemProductVariantID
FROM            dbo.EcomAssortmentItems LEFT OUTER JOIN
                         dbo.EcomProducts ON dbo.EcomAssortmentItems.AssortmentItemProductID = dbo.EcomProducts.ProductID AND 
                         dbo.EcomAssortmentItems.AssortmentItemProductVariantID = dbo.EcomProducts.ProductVariantID
WHERE        (dbo.EcomProducts.ProductID IS NULL) OR
                         (dbo.EcomProducts.ProductVariantID IS NULL)

 

If it returns any records, the listed records are orphaned products in your assortment. This has been fixed with 8.8.0.0.

BR
Snedker

 

Votes for this answer: 1
 
Dmitrij Jazel
Reply

Hi Morten,

Thanks for this query. For some reason it says "LEFT OUTER JOIN" sholdn't it be just "OUTER JOIN" ? 

I just tryed executing this:

SELECT dbo.EcomAssortmentItems.AssortmentItemProductID, dbo.EcomAssortmentItems.AssortmentItemProductVariantID 
FROM dbo.EcomAssortmentItems LEFT INNER JOIN 
        dbo.EcomProducts ON dbo.EcomAssortmentItems.AssortmentItemProductID = dbo.EcomProducts.ProductID AND 
        dbo.EcomAssortmentItems.AssortmentItemProductVariantID = dbo.EcomProducts.ProductVariantID 
WHERE (dbo.EcomProducts.ProductID IS NULL)

And it does not return any records...

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

It's not "for some reason": https://www.google.com/?gws_rd=ssl#q=left+outer+join

Why question (and change) a query you get recommended before trying it out?

There's one small mistake though: I think EcomProducts.VariantID at the end should be EcomProducts.ProductVariantID, no?

 
Dmitrij Jazel
Reply

Hi Imar! :)

cause SSMS told me there was a sintax error, but I can see that there was something wrong when I copied query from forum post.

I took it one more time, and yes you where right. Thanks for that :)

@Morten you query was allright, my mistake.

And now I found 2 records

http://screencast.com/t/iIiCK7oHm0

I guess I should clean them up, right?

/Dmitrij

 
Dmitrij Jazel
Reply

Well, just delete them.

made sure that it was exact those records that where returned by this query.

Than Admin > Rebuild the assortments, but issue still remains.

 

I guess there is no other way but upgrading applicatiuon.

/Dmitrij

 
Morten Snedker
Reply

If you have the tools at hand, you could try activating SQL Profiler and see what SQL statements are executed just before error occurs at backend. Copy-paste those statements to a query window and see if the result gives you an idea of what may be the root cause of the problem. Your "Ids" should be a list of ProductIds that for some reason is empty.

Alternatively you're more than welcome to create a support ticket with a pointer to a copy of the database - then we can quite easily debug our way to the problem.

 

Best regards
Morten Snedker

 
Morten Snedker
Reply

Yes Imar - that is absolutely correct. Is now corrected. :-)

/Snedker

 

You must be logged in to post in the forum