[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3663
  • Last Modified:

Modular Division in Microsoft SQL

I have written a query executed from VB through ADO on an Access database, that I am trying to move to Microsoft SQL Server.  The statment uses modular division in a comparison.  Access is OK with it, but SQL Server generates the following error

[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax near 'MOD'.

The statement goes something like this:

WHERE ((xSys MOD 1000) = (ySys MOD 1000))

I am trying to compare the last x digits of two numbers.

Thanks In Advance

- Michael
0
mjs082969
Asked:
mjs082969
1 Solution
 
AustinSevenCommented:
T-SQL MOD is %

AustinSeven
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now