Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-24 Thread Euler Taveira de Oliveira
Zichen Xu escreveu: Also, I have modified the funscopy.c and every related place where the ^ This file doesn't exist on PostgreSQL source code. Out of curiosity, what another cost metric is for? -- Euler Taveira de Oliveira http://www.timbira.com/ -- Sent

[HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Zichen Xu
Here is my problem and also the question. I'd like adding a field in Path structure and Plan structure as follows: typedef struct Path{ bla bla bla Cost energy_cost; bla bla bla } typedef struct Plan{ bla bla bla Cost energy_cost; bla bla bla } Also, I have modified

Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Robert Haas
On Mon, Feb 23, 2009 at 4:14 PM, Zichen Xu xzckil...@gmail.com wrote: Here is my problem and also the question. I'd like adding a field in Path structure and Plan structure as follows: typedef struct Path{ bla bla bla Cost energy_cost; bla bla bla } typedef struct Plan{

Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Tom Lane
Zichen Xu xzckil...@gmail.com writes: Also, I have modified the funscopy.c and every related place where the other field total_cost appears. Sounds like it should work. Did you recompile everything? Right now, the compile is fine and build is fine. However, everytime the server is running

Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Gregory Stark
Robert Haas robertmh...@gmail.com writes: Attach to the backend with gdb. Then you can get a backtrace, esp. if you've built with --enable-debug. It may be helpful to use lsof to figure out which backend your psql session is connected to. select backend_pid(); is pretty handy for this.

Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Robert Haas
On Mon, Feb 23, 2009 at 4:49 PM, Gregory Stark st...@enterprisedb.com wrote: Robert Haas robertmh...@gmail.com writes: Attach to the backend with gdb. Then you can get a backtrace, esp. if you've built with --enable-debug. It may be helpful to use lsof to figure out which backend your psql

Re: [HACKERS] Adding a field in Path Structure and Plan Structure

2009-02-23 Thread Andrew Dunstan
Tom Lane wrote: Right now, the compile is fine and build is fine. However, everytime the server is running and I send a query to the server, it crashed. as Crashed where? If you're not reasonably handy with gdb or some other favorite debugger, stop what you're doing and go learn one.