Microsoft
Software
Hardware
Network
Question : Display records from two tables, one table missing records
I am using
- MSAccess
- Microsoft SQL Server 2000 - 8.00.760 (Intel X86)
- FrontPage 2002
I have 2 tables: tblGeneral and tblStaff. Both have a common field ChartID.
tblGeneral is the key table in that it has ALL possible ChartIDs. tblStaff is incomplete (does not include all ChartIDs). I am trying to display fields from both tables and want to include all ChartIDs in tblGeneral even if there is no corresponding data in tblStaff.
The results only display records where there are matching ChartID records in both tblGeneral and tblStaff:
My sql statement is:
sql = "SELECT tblGeneral.ChartID, tblGeneral.City, tblGeneral.State, tblGeneral.VISNID, " & _
"tblStaff.LibManTitle, tblStaff.MLS " & _
"FROM tblGeneral INNER JOIN tblStaff ON tblGeneral.ChartID= tblStaff.ChartID "
Answer : Display records from two tables, one table missing records
sql = "SELECT tblGeneral.ChartID, tblGeneral.City, tblGeneral.State, tblGeneral.VISNID, " & _
"tblStaff.LibManTitle, tblStaff.MLS " & _
"FROM tblGeneral LEFT JOIN tblStaff ON tblGeneral.ChartID= tblStaff.ChartID "
Random Solutions
Need help locating drivers for an Acer Aspire 3620
There is an update that will be released in line with exchange 2010 service pack 1 to enable outlook 2007 to 'see' the personal archive?
What does "Func<string, int> method = Work;" do?
Need to see traffic across WAN
WD Mybook world II (Raid 1 - mirror) won't boot
c# last execution time of a process and kiling the last process of the same application
WPF: When might I want a class in the toolbar?
How can i make my pictures display in sequence along with my videos?
How do I automatically set Navigation mode when I enter a form field in Access?
System infected with Security.Hijack can't use Security Center in Window 7 64-bit