Searching product with sku ?

6 years ago
I want to search product with its sku ? In test application there is no sku related with any product.
6 years ago
So, you need to create a pattern to generate your sku code's.

After it you can search by SKU, using IProductService.
6 years ago
Hi,

You need to have SKU for products in database and then need to modify nopCommerce code for enable sku searching.

Please check following post.

https://www.nopcommerce.com/boards/t/29103/search-by-product-id.aspx


Vote +1 if it helps you.

Thanks..
Ajay Saksena
6 years ago
Thanx
6 years ago
fyi - Out of the box, SKU search will work on the advanced search page if you check off "Search In product descriptions"
6 years ago
New York wrote:
fyi - Out of the box, SKU search will work on the advanced search page if you check off "Search In product descriptions"


I found a quirk with what your statement above. YES, that works if there is only one SKU for that product. But if there are more than one SKU for that product, then it dont work. (unless you entered the SKU in the description manually)

I need to figure out how to do SKU searching on my site. :(
Note: I dont do code in VS. Or do I have VS.
6 years ago
I can search by Sku on my 3.30 test site?  But I have NOP Templates  Ajax Filter installed so that probably has something to do with it. They have a free trial version  you could test it  .

Chuck
5 years ago
How will you get searching on SKU working in version 3.50?
4 years ago
Is there an easy answer to this?  To make the search work for the SKU?
4 years ago
Here is what I did on nop 3.5
https://www.nopcommerce.com/boards/t/38514/search-by-sku-how-to-do-it.aspx


Hi,
Use Microsoft SQL Server Managment Studio, open Stored procedure [ProductLoadAllPaged],
After line (61):

IF ISNULL(@Keywords, '') != ''
   BEGIN

Add this:
set @SearchSku = 1


nopCommerce Solution Partner
http://www.nop4you.com
-----------------------------------------------------