Re: [PATCHES] [HACKERS] Add function for quote_qualified_identifier?
Brendan Jurd wrote: On 9/29/07, Bruce Momjian [EMAIL PROTECTED] wrote: I think we need more than one person's request to add this function. Well, I don't expect it would get requested. Most DBAs would likely look for the function in the docs, see it's not there and then just implement it themselves. Obviously it's not critical. But anticipating those little requirements and providing for them is one of the things that makes a piece of software a pleasure to use. Batteries included and all that. I was just looking for someone else to say Yea, I would like that too. Anyway, I seem to be flogging a horse which, if not dead, is surely mortally wounded. If quote_qualified_ident isn't desired, perhaps you can still use the regression test I included for quote_ident in the patch. The test is functional as a standalone item, and seems to fill a gap. Well, we don't test everything and I don't remember problems in quoting in the past, at least not enough to add another test. -- Bruce Momjian [EMAIL PROTECTED]http://momjian.us EnterpriseDB http://postgres.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly
[PATCHES] txid strtoull fix
I noticed strtoull() causes problems on some buildfarm machines. As a fix I propose small str2num function inside txid.c itself. Main reason is that the txid actually does not need fully-featured strtoull (radixes, whitespace skipping). We could include strtoull() under port/ in the future, I think that would be good, but just for txid it is not necessary. -- marko txid.strtoull.diff Description: Binary data ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [PATCHES] txid strtoull fix
Marko Kreen [EMAIL PROTECTED] writes: I noticed strtoull() causes problems on some buildfarm machines. As a fix I propose small str2num function inside txid.c itself. Main reason is that the txid actually does not need fully-featured strtoull (radixes, whitespace skipping). Seems like a sane solution to me --- applied. (Note that your overflow test didn't actually work; AFAIK there really isn't any decent solution other than dividing at each step.) regards, tom lane ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [PATCHES] txid strtoull fix
On 10/8/07, Tom Lane [EMAIL PROTECTED] wrote: Marko Kreen [EMAIL PROTECTED] writes: I noticed strtoull() causes problems on some buildfarm machines. As a fix I propose small str2num function inside txid.c itself. Main reason is that the txid actually does not need fully-featured strtoull (radixes, whitespace skipping). Seems like a sane solution to me --- applied. (Note that your overflow test didn't actually work; AFAIK there really isn't any decent solution other than dividing at each step.) Hmm. It did seem to work here. Just in case I peeked into FreeBSD strtoull() and this patch imitates their method. This also seems to work, but please review, I'm don't feel very sharp anymore... -- marko txid.overflow.diff Description: Binary data ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [PATCHES] [HACKERS] Add function for quote_qualified_identifier?
Bruce Momjian escribió: Brendan Jurd wrote: On 9/29/07, Bruce Momjian [EMAIL PROTECTED] wrote: I think we need more than one person's request to add this function. Well, I don't expect it would get requested. Most DBAs would likely look for the function in the docs, see it's not there and then just implement it themselves. Obviously it's not critical. But anticipating those little requirements and providing for them is one of the things that makes a piece of software a pleasure to use. Batteries included and all that. I was just looking for someone else to say Yea, I would like that too. Probably pgsql-hackers is not the best place to ask. -- Alvaro Herrerahttp://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc. ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [PATCHES] txid strtoull fix
Marko Kreen [EMAIL PROTECTED] writes: On 10/8/07, Tom Lane [EMAIL PROTECTED] wrote: (Note that your overflow test didn't actually work; AFAIK there really isn't any decent solution other than dividing at each step.) Hmm. It did seem to work here. Just in case I peeked into FreeBSD strtoull() and this patch imitates their method. Well, it worked for the one specific case you tested, but there are other cases it would fail to detect overflow for. (When you're multiplying by ten, the overflow might not be small.) The FreeBSD way looks OK though --- applied. regards, tom lane ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq
[PATCHES] Preliminary patch for tsearch example dictionaries/parsers in contrib
Given all the flap about txid, this surely mustn't go in without public review first ;-). So, here is a submission from Sergey Karpov to fill in the lack of any working code examples for user-written tsearch parsers and dictionaries. I will be mostly off-line for the next day or so and don't have time to work on this more now, but here are a few comments: * It seems a bit odd to put multiple independent contrib modules under a single subfolder. I'd be inclined to drop the ts_pack layer and just make the dictionaries and parser be top-level contrib modules. * Depending on PCRE, when we have an at-least-equally-good regex engine built in, is silly. It's an unnecessary dependency and to the (minor) extent that the regex syntax is different, we'd have to document the discrepancies. * dict_regex is not nearly up to speed on encoding or locale issues. I didn't look at the other ones too closely, they may or may not need similar adjustments. * Allowing config files to be read from anywhere is not acceptable. We have dealt with this in the core code and the contrib examples *must* follow the same rules. * The whole utils part of dict_regex should probably go away; it is reinventing wheels that already exist in the Postgres backend environment. Since these are meant to be code examples, they should show the best ways of doing things within Postgres. regards, tom lane bint3RTJXeA1k.bin Description: ts_pack.tar.gz ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster
Re: [PATCHES] Patch to inline stable SQL set returning UDFs
This has been saved for the 8.4 release: http://momjian.postgresql.org/cgi-bin/pgpatches_hold --- [EMAIL PROTECTED] wrote: I discussed this hack with Neil and Josh in Ottawa back in May. I took a stab at it a few weeks ago and below are the results. It is mostly modeled after the existing inline_function. The approach taken is to recursively cleanup the rtable. I've been testing this in our dev environment for a few weeks now. I'm sure it still has issues but I think it is about as clean as I can get it without help from a wider audience. This is my first backend patch so please be gentle. I want to thank Neil for answering many of my supremely ignorant questions on IRC. [ Attachment, skipping... ] ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate -- Bruce Momjian [EMAIL PROTECTED]http://momjian.us EnterpriseDB http://postgres.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(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: [PATCHES] [HACKERS] Function structure in formatting.c
This has been saved for the 8.4 release: http://momjian.postgresql.org/cgi-bin/pgpatches_hold --- Brendan Jurd wrote: I noticed an editing error in the patch I originally submitted; it defined the same debugging macro twice. I've attached a fresh copy of the patch against the current HEAD with the fix included. Cheers, BJ On 8/11/07, Brendan Jurd [EMAIL PROTECTED] wrote: Hello, As discussed on -hackers, I've done some refactoring work on backend/utils/adt/formatting.c, in an attempt to make the code a bit more intelligible before improving handling of bogus formats. This is purely a refactor. The functionality of the file hasn't changed; it does the same job as before, but it does it in ~200 fewer lines and ~3.5k fewer characters. The clarity of code is greatly improved. Sadly, performance appears to be unchanged. Summary of changes: * Did away with dch_global, dch_date and dch_time. * Replaced DCH_processor with two new functions DCH_to_char and DCH_from_char, which now do all the work previously done by dch_{global,date,time}. * Removed the 'action' field from the KeyWord struct as it is no longer useful. * Changed the type of the 'character' field in the FormatNode struct to char, because ... that's what it is. The original choice of 'int' seems to have been an error. * Removed commented-out function declaration for is_acdc. According to CVS annotate, this hasn't been in use since sometime in the early Cretaceous period, and in any case I don't know why you'd want to check whether a string was the rock band AC/DC. =) * Reworded some of the comments for clarity. * Didn't touch any of the number formatting routines. This compiles cleanly on x86 gentoo and passes check, installcheck and installcheck-parallel. Thanks for your time, BJ [ Attachment, skipping... ] ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate -- Bruce Momjian [EMAIL PROTECTED]http://momjian.us EnterpriseDB http://postgres.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [PATCHES] [HACKERS] Use of postmaster
Patch applied. Thanks. Your documentation changes can be viewed on our web site shortly. --- Brendan Jurd wrote: On 10/4/07, Tom Lane [EMAIL PROTECTED] wrote: Brendan Jurd [EMAIL PROTECTED] writes: Now that we've renamed the server binary to postgres, what is the status on use of the name postmaster? Is it now deprecated? And if not, is there any point in keeping it around? We should replace it by terms like server in contexts where it's not actually important to the reader which process is involved, but I think Peter's hit most of them already ... Looks like Peter got the sgml sources pretty well cleaned up, but didn't touch the FAQs. The attached patch replaces some more references to postmaster in the FAQs. Per Tom's guidance, I only replaced those references where I felt a distinction between the postmaster and its children wasn't important to the reader. Thanks for your time, BJ [ Attachment, skipping... ] ---(end of broadcast)--- TIP 6: explain analyze is your friend -- Bruce Momjian [EMAIL PROTECTED]http://momjian.us EnterpriseDB http://postgres.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [PATCHES] pt_BR FAQ update
Patch applied. Thanks. --- Euler Taveira de Oliveira wrote: Hi, An updated pt_BR FAQ patch is attached. If you prefer the complete version, you can get it [1]. There is also a small typo fix. [1] http://timbira.com/tmp/FAQ_brazilian.html -- Euler Taveira de Oliveira http://www.timbira.com/ [ application/x-gzip is not supported, skipping... ] ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings -- Bruce Momjian [EMAIL PROTECTED]http://momjian.us EnterpriseDB http://postgres.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate