Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 8800

Query To Check For Variance Between Stock Code & Supplier Stock Codes

$
0
0

Hello All

I am not sure how to write this query or even if it's possible

 

What I need is a query that

 

  1. Checks the Item Code is the same as the Supplier Item Code.
  2. Only checks items with supplier codes as S1070 & S1075.
  3. Results should only display codes that have a variance.

 

Now my problem is

The item codes have an AD or AT in from of the codes and supplier codes don't.

Examples as below:

 

Item CodeSupplier Code
AT-108-0124108-0124
AD-001-0470001-0470

 

Can the query check for variances like this?

I tried to write the query, but I get an error and I know it's wrong

 

SELECT T0.[ItemCode],

T0.[ItemName]

FROM OITM T0 WHERE T0.[ItemCode] = T0.[SuppCatNum],

T0.[CardCode] = S1070 OR S1075

GROUP BY T0.[ItemCode]

ORDER By T0.[ItemCode]

 

Can someone help me please

 

Thanks & Regards

Rahul


Viewing all articles
Browse latest Browse all 8800

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>