Multiples values SQL Excel

Hello everyone ! I am querying an Excel file. I would like to exclude some code:

“Select * From [Export$] where [Supplier] =‘22’ AND [Product Code] <> ‘101748,101896’”

It doesn’t work, it only takes into account the “101748”. Is there a way to exclude multiple codes at once with <> ?

Thank you !

1 Like

Hi @DimitriLYR

Try the following code & let us know if it works:

Select * From [Export$] where [Supplier] = '22' AND [Product Code] NOT IN ('101748', '101896')

Best Regards.

2 Likes

Incredible, fast efficient it works! THANKS

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.