Re: [HACKERS] Add a filed to PageHeaderData

2014-06-28 Thread Soroosh Sardari
On Tue, Jun 24, 2014 at 10:18 PM, Pavan Deolasee wrote: > > On Tue, Jun 24, 2014 at 3:40 PM, Kevin Grittner wrote: > > > > Soroosh Sardari wrote: > > > > > I check this problem with a virgin source code of > > > postgresql-9.3.2. So the bug is not for

Re: [HACKERS] Add a filed to PageHeaderData

2014-06-24 Thread Soroosh Sardari
On Tue, Jun 24, 2014 at 3:27 PM, Andres Freund wrote: > On 2014-06-24 15:23:54 +0430, Soroosh Sardari wrote: > > On Tue, Jun 24, 2014 at 2:40 PM, Kevin Grittner > wrote: > > > > > Soroosh Sardari wrote: > > > > > > > I check this problem with

Re: [HACKERS] Add a filed to PageHeaderData

2014-06-24 Thread Soroosh Sardari
On Tue, Jun 24, 2014 at 2:40 PM, Kevin Grittner wrote: > Soroosh Sardari wrote: > > > I check this problem with a virgin source code of > > postgresql-9.3.2. So the bug is not for my codes. > > > By the way, following code has two different output and it is > >

Re: [HACKERS] Add a filed to PageHeaderData

2014-06-24 Thread Soroosh Sardari
On Tue, Jun 24, 2014 at 1:34 PM, Pavan Deolasee wrote: > On Tue, Jun 24, 2014 at 2:28 PM, Greg Stark wrote: > >> On Tue, Jun 24, 2014 at 12:02 AM, Soroosh Sardari >> wrote: >> > Is there any rule for adding a field to PageHeaderData? >> >> Not re

Re: [HACKERS] Add a filed to PageHeaderData

2014-06-24 Thread Soroosh Sardari
On Mon, Jun 23, 2014 at 10:23 AM, Soroosh Sardari wrote: > Dear Hackers > > I wanted to add a char array with length of 20 to PageHeaderData in > include/storage/bufpage.h. > Surprisingly regression test failed on rangetypes test! > > The diff of resulted and expected file

[HACKERS] Add a filed to PageHeaderData

2014-06-22 Thread Soroosh Sardari
== Any help appreciated. Soroosh Sardari

[HACKERS] Memory deallocation after calling cast function

2014-06-03 Thread Soroosh Sardari
, Any idea will be appreciated. Soroosh Sardari

[HACKERS] Finding relfilenode

2014-04-24 Thread Soroosh Sardari
Hi In cost functions such as cost_seqscan, a RelOptinfo indicate a base relation. But there is no relfilenode in the RelOptinfo, So how could i find relfilenode or reloid of the relation? Thanks, Soroosh Sardari

[HACKERS] VACUUM for TOASTed objects

2013-11-20 Thread Soroosh Sardari
Hi The vacuum procedure do rewrite for a table but, what happened if the table has some TOASTed columns? Please, help me to find a module or function in source code which is responsible for vaccuming the TOAST relation. Regards, Soroosh Sardari

[HACKERS] Crash recovery

2013-11-05 Thread Soroosh Sardari
Hi When PG crashes or the computer turned down unexpectedly, next time postmaster starts up, it does the crash recovery, actually redo xlog records, vacuum, etc. What module is responsible for crash recovery? Regards, Soroosh Sardari

Re: [HACKERS] RelFileNode to Relation

2013-10-19 Thread Soroosh Sardari
On Sat, Oct 19, 2013 at 11:53 AM, Tom Lane wrote: > Soroosh Sardari writes: > > I need to get a Relation instance but I have only a RelFileNode! > > Why do you think you need to do that? Such a lookup is inherently the > wrong thing, because relations' relfilenode value

[HACKERS] RelFileNode to Relation

2013-10-19 Thread Soroosh Sardari
equivalent to pg_class.relfilenode and in some situation relation oid (pg_class.oid) and relation file node are not the same. So i cant use above function! Any idea? Regards, Soroosh Sardari Sharif University of Tech.

Re: [HACKERS] Planner issue

2013-10-14 Thread Soroosh Sardari
On Mon, Oct 14, 2013 at 10:55 AM, Tom Lane wrote: > Soroosh Sardari writes: > > I developed a new character string type, named myvarchar. > > Also an operator class for btree is added. > > PROBLEM: > > When I executed a query with where clause on 'mine'

Fwd: [HACKERS] Planner issue

2013-10-14 Thread Soroosh Sardari
> 2013/10/14 Soroosh Sardari > >> Hi >> >> I developed a new character string type, named myvarchar. >> Also an operator class for btree is added. >> >> I created a table with two columns, first have myvarchar(100) and other >> is >>

[HACKERS] Planner issue

2013-10-13 Thread Soroosh Sardari
est_myvarchar WHERE 'zagftha' >= plain ORDER BY 2; Index Scan using test_myvarchar_i_plain on test_myvarchar (cost=0.41..6099.0 8 rows=31175 width=197) Index Cond: ('zagftha'::text >= (plain)::text) Why planner does not choose the lowest cost path? Is there any proble

[HACKERS] Pattern matching operators a index

2013-10-10 Thread soroosh sardari
Hi I'm developing a new type for character string, like varchar. I wrote operators for btree and so forth. I wonder how pattern matching operators using btree index, because btree operator class ony knows about >, >=, <=, and = operators, but operators for pattern matching, such as LIKE, are not k

[HACKERS] Pattern matching operators a index

2013-10-09 Thread Soroosh Sardari
Hi I'm developing a new type for character string, like varchar. I wrote operators for btree and so forth. I wonder how pattern matching operators using btree index, because btree operator class ony knows about >, >=, <=, and = operators, but operators for pattern matching, such as LIKE, are not k

Re: [HACKERS] A general Q about index

2013-07-16 Thread soroosh sardari
On Tue, Jul 16, 2013 at 7:00 PM, David Johnston wrote: > David Johnston wrote > > > > soroosh sardari wrote > >> Hi > >> > >> I want to know how an index is created and used. > >> actually if you can show to me a simple start point, it woul

Re: [HACKERS] A general Q about index

2013-07-16 Thread Soroosh Sardari
On Tue, Jul 16, 2013 at 7:00 PM, David Johnston wrote: > David Johnston wrote > > > > soroosh sardari wrote > >> Hi > >> > >> I want to know how an index is created and used. > >> actually if you can show to me a simple start point, it woul

[HACKERS] A general Q about index

2013-07-16 Thread Soroosh Sardari
Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari

[HACKERS] pgsql_tmp and external sort

2013-07-02 Thread Soroosh Sardari
. Regards Soroosh Sardari

[HACKERS] SLRU

2013-06-17 Thread Soroosh Sardari
Hey I was reading the multi transaction log manager, multixact.c. I didn't get what SLRU does. I want the goal of this module, and why we use it. I'm kind of newbie, be patient with me ;) Regards Soroosh

Re: [HACKERS] Which table stored in which file in PGDATA/base/[db-oid]

2013-06-02 Thread Soroosh Sardari
On Sat, Jun 1, 2013 at 3:57 PM, Andres Freund wrote: > On 2013-06-01 13:04:55 +0200, Martijn van Oosterhout wrote: > > On Sat, Jun 01, 2013 at 03:27:40PM +0430, Soroosh Sardari wrote: > > > Yes, I have some files which is not in pg_class.relfilenode of any > table or > &g

Re: [HACKERS] Which table stored in which file in PGDATA/base/[db-oid]

2013-06-01 Thread Soroosh Sardari
e.pg : Set of oids which exists in newfile.pg and does not in filenode.pg On Sat, Jun 1, 2013 at 3:34 PM, Martijn van Oosterhout wrote: > On Sat, Jun 01, 2013 at 03:27:40PM +0430, Soroosh Sardari wrote: > > Yes, I have some files which is not in pg_class.relfilenode of any table > or

Re: [HACKERS] Which table stored in which file in PGDATA/base/[db-oid]

2013-06-01 Thread Soroosh Sardari
Yes, I have some files which is not in pg_class.relfilenode of any table or index. I want to know which table or index stored in such files. > From that page: > > Each table and index is stored in a separate file. For ordinary > relations, these files are named after the table or index's filenod

[HACKERS] Which table stored in which file in PGDATA/base/[db-oid]

2013-06-01 Thread Soroosh Sardari
Dear Hackers I've created a new DB, and a bunch of files created in base/12054, 12054 is oid of the new DB. I want to find what table stored in each file. BTW, I read this http://www.postgresql.org/docs/9.2/interactive/storage-file-layout.html I have 156 files with numerical names, vm and fsm fil

Re: [HACKERS] Why there is a union in HeapTupleHeaderData struct

2013-05-20 Thread Soroosh Sardari
fields. > > > especially the last line points as to what roles each of them plays, > though, I would like to hear more about additional details from others > who might reply. > > > > On Mon, May 20, 2013 at 4:28 PM, Soroosh Sardari > wrote: > >

[HACKERS] Why there is a union in HeapTupleHeaderData struct

2013-05-20 Thread Soroosh Sardari
Dear Hackers In fix part oh HeapTuple, there is a union that is named t_choice, union { HeapTupleFields t_heap; DatumTupleFields t_datum; }t_choice; I can't find out why we need t_datum, actually there is no comment about DatumTupleFields. Regards Soroosh

Re: [HACKERS] Road map to study about fetching a set of tuples - novice!

2013-05-18 Thread Soroosh Sardari
SSAGE- > > Hash: SHA1 > > > > Em 18-05-2013 11:40, Atri Sharma escreveu: > >> On 18-May-2013, at 20:01, Soroosh Sardari > >> wrote: > >> > >>> Hi > >>> > >>> I was tracing a simple SELECT query to find how pg work

[HACKERS] Road map to study about fetching a set of tuples - novice!

2013-05-18 Thread Soroosh Sardari
Hi I was tracing a simple SELECT query to find how pg works for fetching tuples. but I'm totally lost in the code. Could you help me to understand under the hood? I know about parsing and planning parts, my actual problem is executer. If you show me a road map to study, I would appreciate it. Reg

Re: [HACKERS] Meaning of keyword category list in src/backend/parser/gram.y

2013-05-06 Thread soroosh sardari
Dear Amit yes, my new constrains must not be name of variable. I moved new keyword to reserved keyword. Problem solved :D Regards Soroosh On Mon, May 6, 2013 at 10:17 AM, Amit Kapila wrote: > On Sunday, May 05, 2013 1:03 PM soroosh sardari wrote: > > Hi > > I'm

[HACKERS] Meaning of keyword category list in src/backend/parser/gram.y

2013-05-05 Thread soroosh sardari
Hi I'm trying to add a new constraint to column constraint. I add a new keyword ro kwlist.h and gram.y, and also edit ColConstraintElem. The problem is i don't know what is "Keyword category lists" at the end of gram.y. when I added the new keyword in "unreserved_keyword", shift/reduce and reduce