Re: [GENERAL] join from multiple tables

2010-03-05 Thread Grzegorz Jaśkiewicz
altho not an answer to your question, you might want to start using table name aliases, to make queries more readable. so instead of: SELECT dsclient_logs.ev_id,dsclient_ logs.type,to_timestamp(dsclient_logs.ev_time) as timestamp,dsclient_logs.category,dsclient_logs.error,dsclient_logs.ev_text,ds

Re: [GENERAL] join from multiple tables

2010-03-04 Thread Terry
On Thu, Mar 4, 2010 at 1:44 PM, Terry wrote: > On Thu, Mar 4, 2010 at 11:43 AM, Terry wrote: >> On Thu, Mar 4, 2010 at 11:33 AM, Thom Brown wrote: >>> On 4 March 2010 17:26, Terry wrote: I have 4 tables: dsclient_logs,backup_sets,dsbox,customer.  I want a query that will return a

Re: [GENERAL] join from multiple tables

2010-03-04 Thread Terry
On Thu, Mar 4, 2010 at 11:43 AM, Terry wrote: > On Thu, Mar 4, 2010 at 11:33 AM, Thom Brown wrote: >> On 4 March 2010 17:26, Terry wrote: >>> >>> I have 4 tables: dsclient_logs,backup_sets,dsbox,customer.  I want a >>> query that will return all rows from dsclient_logs, insert two columns >>> fr

Re: [GENERAL] join from multiple tables

2010-03-04 Thread Terry
On Thu, Mar 4, 2010 at 11:33 AM, Thom Brown wrote: > On 4 March 2010 17:26, Terry wrote: >> >> I have 4 tables: dsclient_logs,backup_sets,dsbox,customer.  I want a >> query that will return all rows from dsclient_logs, insert two columns >> from the customer table, and one column from backup_sets

Re: [GENERAL] join from multiple tables

2010-03-04 Thread Thom Brown
On 4 March 2010 17:26, Terry wrote: > I have 4 tables: dsclient_logs,backup_sets,dsbox,customer. I want a > query that will return all rows from dsclient_logs, insert two columns > from the customer table, and one column from backup_sets. The > relation is this: > > dsclient_logs.userid = dsbox