Re: Analysis Function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

The C function returns a DateADT, which is a typedef for int32, but the CREATE FUNCTION statement claims that it returns 'text'.

That'll do it. Thank you!

but whether that is faster or slower I don't know. But I
don't see why this query needs to be fast in the first
place. It seems to be interactive, and therefore I wouldn't

When users click the button, I want the result returned in in less under 4 seconds. Right now it is closer to 10. Consequently, they click twice. Shaving 2 seconds here and there will make a huge difference. It will also allow the computer to handle a higher volume of requests.
 
invest too much time to have the user wait not 4.4, but
2.2 seconds. You could also do the concatenation in the ap-
plication if that is faster than PostgreSQL's date arithme-
tics.

No, I cannot. The concatenation uses the year that the measurement was made--from the database--and the month/day combination from the user. See also:

http://stackoverflow.com/questions/2947105/calculate-year-for-end-date-postgresql

Dave


[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux