Re: [SQL] lower() not working correctly...?

2006-09-15 Thread Amit_Wadhwa
unsubscribe ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Re: [SQL] Complex Query - Data from 3 tables simultaneously

2005-10-28 Thread Amit_Wadhwa
SELECT a.*,b.*,c.*,c.issuedate-a.recd_date as age FROM shipments a LEFT JOIN materials b ON a.shipid = b.shipid;LEFT JOIN issuetable c ON b.material_id = c.material_id WHERE (a.recd_date between cast(' "+date1+" 00:00:00' as datetime) and cast(' "+date2 + ' ") 23:59:59' as datetime) Did the

Re: [SQL] Complex Query - Data from 3 tables simultaneously

2005-10-27 Thread Amit_Wadhwa
Thanks a lot, that worked for me! -Original Message- From: Richard Huxton [mailto:[EMAIL PROTECTED] Sent: Thursday, October 27, 2005 2:47 PM To: Wadhwa, Amit Cc: pgsql-sql@postgresql.org Subject: Re: [SQL] Complex Query - Data from 3 tables simultaneously [EMAIL PROTECTED] wrote: > >

Re: [SQL] How to speed up the database query?

2005-10-27 Thread Amit_Wadhwa
Run an analyse on your query, create your indexes according to that, and you have a better performing query. Getting a resultset display faster will depend on your driver/RAM/client -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Abdul Wahab Dahalan Sent:

[SQL] Complex Query - Data from 3 tables simultaneously

2005-10-27 Thread Amit_Wadhwa
All,   Using Postgres 8.0 on Windows Server 2003 - 16GB Ram, 3Ghz X 2 Xeons Accessing through JDBC / JSP   I have 3 shipment tables. Table A - Records arrived Shipments. Table B - Records Materials (maybe more than one per shipment) in the shipment. Table C - Records Issuances of material (

Re: [SQL] Time differences between rows, not columns?

2005-08-30 Thread Amit_Wadhwa
Thanks! Amit,You say "I want to know how much time it took for a bill to be accepted after it was submitted" So, do you want between 10 and 40, not 10 and 20? I assume you meant 10 and 40... ...Could be any status to any status, I wanted to generalize the concept for future usage. I tried the b

[SQL] Time differences between rows, not columns?

2005-08-30 Thread Amit_Wadhwa
Using postgresSQL 8.0 for windows, running on windows 2003 server 16gb RAM, 3Ghz dual p4. Language: Java - JDBC postgres driver: postgresql-8.0-310.jdbc3.jar I have an application with 3 tables (in this context that is) Table bills bill_id NOT NULL serial ... And other columns Table bill