About 486,000 results
Open links in new tab
  1. % (Modulus) (Transact-SQL) - SQL Server | Microsoft Learn

    Nov 22, 2024 · You can use the modulo arithmetic operator in the select list of the SELECT statement with any combination of column names, numeric constants, or any valid expression …

  2. SQL MOD() function - w3resource

    Apr 20, 2024 · The SQL DISTINCT command along with the SQL MOD() function is used to retrieve only unique records depending on the specified column or expression. Syntax: MOD( …

  3. SQL MOD: Returns Modulus of a Number Divided by Another

    In this tutorial, you will learn how to use the SQL MOD function that returns the remainder of one number divided by another.

  4. sql - 'MOD' is not a recognized built-in function name - Stack Overflow

    Apr 26, 2014 · In TSQL, the modulo is done with a percent sign. for your exact sample, it should be like this. It can be done using the % operator. If using JDBC driver you may use function …

  5. SQL Server MOD equivalent - Stack Overflow

    Jun 10, 2016 · I know SQL Server MOD is written as % but that usually requires a number % number. My question is how can I use the % when I have these clauses in the code: SELECT …

  6. MOD () in SQL: Examples, Use Cases & Error Handling

    What is MOD() in SQL? The MOD() function in SQL returns the remainder after dividing one number by another. It is commonly used for checking divisibility, cyclic operations, and …

  7. Unleashing the Power of SQL Server Modulo - UnSQL AI

    Aug 18, 2023 · SQL Server provides the MOD() function as a built-in mathematical function to perform modulo calculations. The MOD() function takes two arguments: the dividend and the …

  8. SQL query - mod function - how can I use it to group results?

    Mar 27, 2013 · It sounds like this is what you're looking for -- use the % operator to perform a Mod: select a % 2, sum(b) from yourtable group by a % 2 Condensed SQL Fiddle Demo. To …

  9. Mastering the MOD Function in SQL: A Comprehensive Guide to …

    Jun 12, 2024 · The MOD function, while straightforward, can be leveraged in creative ways to enhance the performance and clarity of SQL queries. This section shares best practices, …

  10. The SQL MOD FunctionSQL And Its Sequels - Ocelot

    Aug 4, 2020 · And so R = N MOD M means get a result R by applying to a number N “by means of the modulus M“. In SQL this is the standard function MOD(N, M) or the common operator N …

  11. Some results have been removed
Refresh