Click here to Skip to main content
15,905,420 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: Mini CCCs 67 - Done Pin
Tim Deveaux4-Apr-19 21:09
Tim Deveaux4-Apr-19 21:09 
GeneralMini CCCs 66 Pin
Tim Deveaux4-Apr-19 18:45
Tim Deveaux4-Apr-19 18:45 
GeneralRe: Mini CCCs 66 Pin
GKP19924-Apr-19 19:02
professionalGKP19924-Apr-19 19:02 
GeneralRe: Mini CCCs 66 - Done Pin
Tim Deveaux4-Apr-19 19:04
Tim Deveaux4-Apr-19 19:04 
GeneralMini CCCs 65 Pin
Tim Deveaux4-Apr-19 18:28
Tim Deveaux4-Apr-19 18:28 
GeneralRe: Mini CCCs 65 Pin
Randor 4-Apr-19 18:35
professional Randor 4-Apr-19 18:35 
GeneralRe: Mini CCCs 65 - Done Pin
Tim Deveaux4-Apr-19 18:36
Tim Deveaux4-Apr-19 18:36 
GeneralHELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 16:33
BrunoPigeon4-Apr-19 16:33 
Hi all. I have two tables in access (VB6): SupplierInvoices & Sales. They both have 3 common field names: Date, Code & Qty. I need to query both tables via SQL query by a specific date range as follows (I know this is wrong, but just to give you an idea):
VB
rs.Open "Select distinct format(SupplierInvoices.Date, 'dd-MMM-yyyy') as tDate, Sum(SupplierInvoices.QTY) as tTotal from SupplierInvoices, format(Sales.Date, 'dd-MMM-yyyy') as sDate, Sum(Sales.QTY) as sTotal from Sales where PLU = '" & lblPLU.Caption & "' and Date Between #" & StartTime & "# and #" & EndTime & "# Group by format(SupplierInvoices.Date, 'dd-MMM-yyyy');", cn, adOpenKeyset, adLockOptimistic

The result needs to return from both tables the sum of the qty fields for that date range. I can't get it right! Please help.

modified 5-Apr-19 0:46am.

GeneralRe: HELP WITH SQL QUERY PinPopular
Tim Deveaux4-Apr-19 17:35
Tim Deveaux4-Apr-19 17:35 
GeneralRe: HELP WITH SQL QUERY Pin
PIEBALDconsult4-Apr-19 18:46
mvePIEBALDconsult4-Apr-19 18:46 
GeneralRe: HELP WITH SQL QUERY Pin
User 48350474-Apr-19 19:48
User 48350474-Apr-19 19:48 
GeneralRe: HELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 19:53
BrunoPigeon4-Apr-19 19:53 
GeneralRe: HELP WITH SQL QUERY Pin
User 48350474-Apr-19 20:01
User 48350474-Apr-19 20:01 
GeneralRe: HELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 20:08
BrunoPigeon4-Apr-19 20:08 
GeneralRe: HELP WITH SQL QUERY Pin
User 48350474-Apr-19 20:13
User 48350474-Apr-19 20:13 
GeneralRe: HELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 20:29
BrunoPigeon4-Apr-19 20:29 
GeneralRe: HELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 20:32
BrunoPigeon4-Apr-19 20:32 
GeneralRe: HELP WITH SQL QUERY Pin
Mycroft Holmes4-Apr-19 20:33
professionalMycroft Holmes4-Apr-19 20:33 
GeneralRe: HELP WITH SQL QUERY Pin
BrunoPigeon4-Apr-19 20:36
BrunoPigeon4-Apr-19 20:36 
GeneralHuge Mistake Pin
#realJSOP4-Apr-19 8:34
professional#realJSOP4-Apr-19 8:34 
GeneralRe: Huge Mistake Pin
Mark_Wallace4-Apr-19 8:50
Mark_Wallace4-Apr-19 8:50 
GeneralRe: Huge Mistake Pin
#realJSOP4-Apr-19 9:07
professional#realJSOP4-Apr-19 9:07 
GeneralRe: Huge Mistake Pin
Mark_Wallace4-Apr-19 9:23
Mark_Wallace4-Apr-19 9:23 
GeneralRe: Huge Mistake Pin
kmoorevs4-Apr-19 9:49
kmoorevs4-Apr-19 9:49 
GeneralRe: Huge Mistake Pin
John R. Shaw4-Apr-19 10:27
John R. Shaw4-Apr-19 10:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.