About 50 results
Open links in new tab
  1. How do I perform an IF...THEN in an SQL SELECT?

    Sep 15, 2008 · The CASE statement is the closest to IF in SQL and is supported on all versions of SQL Server.

  2. SQL WITH clause example - Stack Overflow

    Sep 23, 2012 · 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 called sub-query …

  3. Nested select statement in SQL Server - Stack Overflow

    Check for more subquery rules and subquery types. More examples of Nested Subqueries. IN / NOT IN – This operator takes the output of the inner query after the inner query gets executed which can be …

  4. How to use a SQL SELECT statement with Access VBA

    Jun 13, 2012 · I have a combobox whose value I want to use with a SQL WHERE clause. How do you run a SELECT statement inside VBA based on the combobox value?

  5. sql - Insert into ... values ( SELECT ... FROM ... ) - Stack Overflow

    Aug 25, 2008 · Is there a silver-bullet syntax coming from an SQL standard (for example, SQL-92) that would allow me to insert the values without worrying about the underlying database?

  6. sql - Using group by on multiple columns - Stack Overflow

    Mar 10, 2010 · When using GROUP BY x statement, it fetches rows for each distinct value of column x. When using GROUP BY x, y statement, it fetches rows for each unique pair of values of column x …

  7. excel - How to use a SQL Select statement with Power Query against an ...

    Oct 21, 2022 · Instead of creating 16 Power Queries and joining them into 4 queries (20 total query objects) I want to write a SQL statement that joins the tables and run it against each of the 4 different …

  8. SQL Server query to find all permissions/access for all users in a ...

    Aug 13, 2011 · 291 I would like to write a query on a sql 2008 that will report all the users that have access to a specific database, or objects within the database such as tables, views, and stored …

  9. 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 OrderNumber LIKE '%' + @

  10. sql - What is the difference between JOIN and UNION? - Stack Overflow

    May 25, 2009 · 3 The SQL JOIN clause is used to combine records from two or more tables in a database. A JOIN is a means for combining fields from two tables by using values common to each. …