About 2,710,000 results
Open links in new tab
  1. SQL: IF clause within WHERE clause - Stack Overflow

    Sep 18, 2008 · Is it possible to use an IF clause within a WHERE clause in MS SQL? Example: WHERE IF IsNumeric(@OrderNumber) = 1 OrderNumber = @OrderNumber ELSE …

  2. sql server 2008 - SQL query with NOT LIKE IN - Stack Overflow

    May 22, 2023 · SQL query with NOT LIKE IN Asked 13 years, 8 months ago Modified 2 years, 5 months ago Viewed 568k times

  3. SQL WITH clause example - Stack Overflow

    Sep 23, 2012 · 353 The SQL WITH clause was introduced by Oracle in the Oracle 9i release 2 database. The SQL WITH clause allows you to give a sub-query block a name (a process also …

  4. sql - Incorrect syntax near '' - Stack Overflow

    I'm trying to run the following fairly simple query in SQL Server Management Studio: SELECT TOP 1000 * FROM master.sys.procedures as procs left join master.sys.parameters as params …

  5. SQL Server tables: what is the difference between @, # and

    Feb 8, 2010 · In SQL Server, what is the difference between a @ table, a # table and a ## table?

  6. sql server - Database stuck in "Restoring" state - Stack Overflow

    Ran into a similar issue while restoring the database using SQL server management studio and it got stuck into restoring mode. After several hours of issue tracking, the following query worked …

  7. sql - Exclude a column using SELECT * [except columnA] FROM …

    FROM TableA This very powerful SQL syntax avoids a long list of columns that must be constantly updated due to table column name changes. This functionality is missing in the …

  8. sql - Must declare the scalar variable - Stack Overflow

    @RowFrom int @RowTo int are both Global Input Params for the Stored Procedure, and since I am compiling the SQL query inside the Stored Procedure with T-SQL then using …

  9. sql - Access the "previous row" value in a SELECT statement - Stack ...

    SQL has no built in notion of order, so you need to order by some column for this to be meaningful. Something like this: select t1.value - t2.value from table t1, table t2 where …

  10. Convert Rows to columns using 'Pivot' in SQL Server

    Apr 10, 2013 · Pivot is one of the SQL operator which is used to turn the unique data from one column into multiple column in the output. This is also mean by transforming the rows into …