How To Select Rows in MySQL with No Matching Entry in Another Table

Author: , May 16th, 2018

SELECT t1.id FROM tableOne t1 LEFT JOIN tableTwo t2 ON t1.id = t2.id WHERE t2.id IS NULL The “WHERE t2.id IS NULL clause” restricts the results to only those rows where the id returned from tableTwo is null. tableTwo.id will be NULL for all records from tableOne where the id is not found in tableTwo.

How To Get the URL in Javascript Without the Query String

Author: , August 29th, 2013

window.location.href.split(‘?’)[0]

How To Create a List of Reports, Queries or Tables in Microsoft Access

Author: , February 25th, 2012

This query will list the names of the reports in the database: SELECT MSysObjects.Name AS Report_Name FROM MSysObjects WHERE (((MSysObjects.Type)=-32764)) ORDER BY MSysObjects.Name; This query will list the names of the queries in the database: SELECT MSysObjects.Name FROM MSysObjects WHERE (((MSysObjects.Type)=5)); This query will list the names of the tables in the database: SELECT MSysObjects.Name […]

How To Return Line Numbers In MySQL

Author: , October 14th, 2011

1 2 3 4 5 6 SELECT @rownum := @rownum + 1 AS Rank, T1.* FROM (select @rownum := 0) R, (    SELECT Category, Item, Value FROM Inventory    WHERE lastUpdated = CURDATE()    ORDER BY Value DESC ) AS T1 WHERE T1.Item = "Camera" SELECT @rownum := @rownum + 1 AS Rank, T1.* […]