Re: [GENERAL] How to debug this crash?

2007-02-27 Thread Jorge Godoy
7;out' parameter as it was before and also being able to reference variables directly without resorting to using the args array...) TIA, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 3: Have you checked our extensiv

Re: [GENERAL] How to debug this crash?

2007-02-27 Thread Jorge Godoy
Tom Lane <[EMAIL PROTECTED]> writes: > Jorge Godoy <[EMAIL PROTECTED]> writes: >> This is with: > >> OpenSuSE 10.2 >> postgresql-server-8.1.5-13 >> postgresql-libs-8.1.5-13 >> postgresql-docs-8.1.5-13 >> postgresql-devel-8.1.5-13 >> p

[GENERAL] How to debug this crash?

2007-02-27 Thread Jorge Godoy
sh dts acpi mmx fxsr sse sse2 ss ht tm pbe constant_tsc up pni monitor ds_cpl est tm2 cid xtpr bogomips : 6137.03 (HT is disabled) So, my doubt is: where do I start debugging that? :-) Thanks for any help, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] performance of partitioning?

2007-02-27 Thread Jorge Godoy
artition it only contains the records from that specific partition. When checking from the parent table it contains records for all partitions. Also note that an index on interval wouldn't be helpful here, I believe, due to the fact that data is in a different table and not on the parent one. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Composite Keys

2007-02-24 Thread Jorge Godoy
the number of left recipes on each receipt book or when to order new books. If you use the date take special care with long term payments so that you don't have two recipes "10" scheduled for the same day. -- Jorge Godoy <[EMAIL PROTECTED]> ---

Re: [GENERAL] daylight savings patches needed?

2007-02-13 Thread Jorge Godoy
DST starts / ends and PostgreSQL doesn't release a new version with the changes (or a patch or...) then you would have to change this in two places: your OS rules and PG's rules for timezones / DST / whatever. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of b

Re: [GENERAL] leaving this group

2007-02-06 Thread Jorge Godoy
Post: <mailto:pgsql-general@postgresql.org> List-Subscribe: <mailto:[EMAIL PROTECTED]> List-Unsubscribe: <mailto:[EMAIL PROTECTED]> -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 9: In versions below 8.0, the

Re: [GENERAL] ERROR: missing cache data for cache id 27

2007-02-04 Thread Jorge Godoy
Tom Lane <[EMAIL PROTECTED]> writes: > Jorge Godoy <[EMAIL PROTECTED]> writes: >> I'm using PostgreSQL 8.1.4 and psql 8.1.4 as well. > > This was fixed in 8.1.5 ... or at least the only known cause was fixed. Thanks! I'll bug OpenSuSE guys to release

[GENERAL] ERROR: missing cache data for cache id 27

2007-02-04 Thread Jorge Godoy
If I drop the first function, then I can REPLACE the second. If I don't, then I get the missing cache error for both. Is there some way to reset this cache so that I can investigate the cause of the problem or would I have to recreate the database (i.e. a dump + dropdb + createdb + restore)?

[GENERAL] [1/2 OFF] Update on Varlena.com Access problem

2007-02-03 Thread Jorge Godoy
Hi! Just to let you know that I've just tried to access Varlena.com again and it worked. I'm just reporting it here because of the "noise" I caused when I asked if there was any blocking. :-) Thanks for whoever solved that! Be seeing you, -- Jorge Godoy

Re: [GENERAL] sequence skips 30 values, how?

2007-02-01 Thread Jorge Godoy
just easier on the eyes to have 1,2,3,4,5 than 1, > 25, 2405, 95720, 59028598253. There's a recipe for gapless sequences on Varlena (if you can access it from your end...) that was the result of discussions here. There's a performance hit, of course, but it works. -- J

Re: [GENERAL] Any Plans for cross database queries on the same server?

2007-01-31 Thread Jorge Godoy
artitioning and legacy systems integration... -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] PostgreSQL 9.0

2007-01-30 Thread Jorge Godoy
resql.org/docs/8.2/interactive/rules.html) (They exist for a while, I've just linked the latest released docs...) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-23 Thread Jorge Godoy
en I tried accessing using an UNC account it worked perfectly, so it wasn't a problem with the machine being down. Could you check with your ISP if they're blocking us from down here? ;-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)

Re: [GENERAL] show all record between two date after group by and aggrigation...

2007-01-23 Thread Jorge Godoy
for the date part, the simpler alternative: SELECT CURRENT_DATE + s.s AS DATE FROM generate_series(1, 365) AS s; ? Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Spam from EnterpriseDB?

2007-01-18 Thread Jorge Godoy
reported their spam to spamcop... It is nice that I got 3 messages from them, one for each email of mine, so they got a bit more of spam status at the bayesian filters I manage and also were reported 3 times to some anti-spam services. -- Jorge Godoy <[EMAIL PROTECTED]> -

Re: [GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-18 Thread Jorge Godoy
#x27;s nothing on my networks and firewalls that is blocking Varlena on my side... If anybody could pass these messages to them, I believe that we (the blocked people) would all be very grateful if we get to be able to access it again or just get a notice that they'll block us foreve

Re: [GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-18 Thread Jorge Godoy
block to the Cicarelli video was removed, though. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org/

Re: [GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-17 Thread Jorge Godoy
o see if it That website opens fine. > is a general block. If you use traceroute, tell it to use icmp, not udp as > wolff.to will drop udp packets that aren't destined for a public service > or part of an existing conversation. So, I believe that there might be something on Va

Re: [GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-17 Thread Jorge Godoy
s from different carriers. The traffic stops at speakeasy from my house (ADSL from GVT, it also happens from Brasil Telecom and using radio at the São Paulo state -- I'm in a different state, a partner lives in São Paulo and tested it for me). -- Jorge Godoy <[EMAIL PROTECTED]> --

[GENERAL] [1/2 OFF] Varlena.com inaccessible from .br (Blocked?)

2007-01-16 Thread Jorge Godoy
d I know that people from there are subscribed here to this mailing list... TIA, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [GENERAL] Improve Postgres Query Speed

2007-01-15 Thread Jorge Godoy
o a select statement, the speed has also > degraded. And it is expected to be like that if you filter on unindexed columns... Maybe you should go back to design and fix this :-) (Remember that too much indices is also bad.) -- Jorge Godoy <[EMAIL PROTECTED]> --

Re: [GENERAL] Linking tables and indexes

2007-01-15 Thread Jorge Godoy
;ll need > the primary key anyway, in which case leave the PK alone and create > another index on (document_client_id). ... I haven't thought on this and it is much better :-) I played with some possibilities and I forgot mixing a composed index with a simple one... :-) This is what I we

Re: [GENERAL] Improve Postgres Query Speed

2007-01-15 Thread Jorge Godoy
then you won't gain much with them... E.g. "UPDATE my_messages SET rpt_generated='Y' WHERE rpt_generated='N';" won't use any of those indices and will seq scan the whole table. -- Jorge Godoy <[EMAIL PROTECTED]> ---(

Re: [GENERAL] Transaction callback

2007-01-15 Thread Jorge Godoy
lieve that you'll be wanting to take a look at the NOTIFY and LISTEN commands. http://www.postgresql.org/docs/8.1/interactive/sql-notify.html http://www.postgresql.org/docs/8.1/interactive/sql-listen.html Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

[GENERAL] Linking tables and indexes

2007-01-15 Thread Jorge Godoy
EX something ON ged.documents_clients_cis (document_client_id, ci_id)") or I'd only be wasting disk and processing? The query can be done from either side (i.e. I might know either ci_id or document_client_id only). Thanks for your attention, -- Jorge Godoy <[EMAIL PROTECTED]> ---

Re: [GENERAL] Sorting with DISTINCT ON

2007-01-08 Thread Jorge Godoy
t; path because of DISTINCT ON (path). It does allow you to sort on both columns. SELECT DISTINCT ON (path) path, comment_id, created, title FROM bewertungen.tblcomments ORDER BY path, created Maybe you need a more complex query to get what you want (and use max(created)...). -

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
an anyone that listen to and learn with other people. I am still learning here since I'm really a newbie in this database world. Thanks for that, though :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
eferential integrity would be guaranteed by the database itself and I won't have any pointers to files that doesn't exist or files without pointers to it. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
e image paths from the > database and and have apache server the data; select images paths from php or > something. Now you can have the data anywhere, on a different server, over an > nfs mount, gfs, wherever. Much more flexible and distributed. And also more uncertain that the referred

Re: [GENERAL] Continue sequence

2007-01-05 Thread Jorge Godoy
can use google's cache: http://209.85.165.104/search?q=cache:wCm4AMkEbA4J:www.varlena.com/GeneralBits/130.php+gapless+sequence+postgresql -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting/reading through

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
content and then replace the old file with this one. There are also cases where you can keep a file descriptor open to one file that has no name (it existed once) and that was replaced. It all depends on how / who's generating and how / who's consuming the information. -- Jorge Godoy

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
corresponding entries on the database. Couting them is not enough since I can have one file with the wrong "name" present on the filesystem or some duplicate record on the DB... -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
nking about referential integrity with those files? -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
atabase. Not counting that depending on your choice of filesystem and image size you might get a very poor performance. -- Jorge Godoy <[EMAIL PROTECTED]> ---(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: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
and without losing > anything. So there ;) Anyway, you have no guarantee that all your images exist on file and that all existing files have a corresponding entry in your database. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)

Re: [GENERAL] Database versus filesystem for storing images

2007-01-05 Thread Jorge Godoy
u guarantee that on a failure all needed data is restored? I mean, how do you handle integrity with data outside the database? -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please sen

Re: [GENERAL] Let's play bash the search engine

2006-12-18 Thread Jorge Godoy
its fast & quick tho :-) Indeed. Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Creating multiple Rules for on update

2006-12-11 Thread Jorge Godoy
RULE with your filtering conditions AND add an unqualified RULE that is always run - use an unqualified RULE and call a function that will perform the action for you on the right tables I believe the second solution leads to cleaner code and is easier to update / debug. But I

Re: [GENERAL] Numeric or Integer for monetary values?

2006-12-11 Thread Jorge Godoy
e a company) instead of truncation... Dealing with money is a really complex subject and requires a lot of planning. My recommendation is to get two decimal places more than needed to avoid rounding issues (and if you need truncation, the truncate only at the very end where you&#x

Re: [GENERAL] Male/female

2006-12-08 Thread Jorge Godoy
to inform the gender. To cover all these possibilities with one single column we need a set of discrete states. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Male/female

2006-12-08 Thread Jorge Godoy
ortant, then there should be some way to point that. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED]

Re: [GENERAL] IS it a good practice to use SERIAL as Primary Key?

2006-11-23 Thread Jorge Godoy
u anticipate > the use of more than 231 identifiers over the lifetime of the table. "" > http://www.postgresql.org/docs/8.2/interactive/datatype-numeric.html#DATATYPE-SERIAL What would be those "231 identifiers"? -- Jorge Godoy <[EMAIL PRO

Re: [GENERAL] Multiple currencies in a application

2006-11-22 Thread Jorge Godoy
sent S&H costs, import / export taxes, etc. and how this will impact on the value you'll be showing to the user. This is just the tip of the iceberg, but I hope it helps a little to see what is important or not for you. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: RE : Re: [GENERAL] database design ...

2006-11-15 Thread Jorge Godoy
correct field... Also remember that barcode readers can be programmed to "press" TAB / ENTER after reading. If you're on a web application this might submit the form instantaneously so take care with that. Most of them come with a default to "press" ENTER after re

Re: [GENERAL] Why isn't it allowed to create an index in a schema other than public?

2006-11-12 Thread Jorge Godoy
Tom Lane <[EMAIL PROTECTED]> writes: > Jorge Godoy <[EMAIL PROTECTED]> writes: >> I'd like to know if there's any reasoning for not allowing creating an index >> inside the same schema where the table is. > > Actually, you've got that exactly back

Re: [GENERAL] Why isn't it allowed to create an index in a schema other than public?

2006-11-12 Thread Jorge Godoy
n says: D'oh! :-) I've seen it now... I just can't specify where the index should go, it always goes with the table... That's fine... My fault... I need to rest on the weekend, not start having those crazy ideas about where indices go... :-) -- Jorge Godoy <[EMAIL PROTECTED

Re: [GENERAL] Why isn't it allowed to create an index in a schema other than public?

2006-11-12 Thread Jorge Godoy
ere's some reason (such as performance gain, for example) for that decision. Using this approach, though, doesn't group all items that belong to a schema inside of it. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)---

[GENERAL] Why isn't it allowed to create an index in a schema other than public?

2006-11-12 Thread Jorge Godoy
=== (I wouldn't mind if the autogenerated index for the PK was created on the public schema if no specific name was supplied.) This would also help identifying all objects to make a certain feature available and where they belong to on the database... TIA, -- Jorge Godoy

Re: [GENERAL] DB Designer??

2006-11-12 Thread Jorge Godoy
ts using 5K tables know what I mean :-)) It shouldn't be -- graphically -- all that hard to implement this separation... So I believe it might be something they hold a patent for because I've never seen another tool with this feature. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Why overlaps is not working

2006-11-11 Thread Jorge Godoy
d work for you, but instead of using NULL to > represent infinity, why not use 'infinity' to represent infinity? If he casts all his dates to timestamps then this might be a good option. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)

Re: [GENERAL] Why overlaps is not working

2006-11-11 Thread Jorge Godoy
u can time it. :-) But I don't believe it will be too slow since it is a simple operation... -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Why overlaps is not working

2006-11-09 Thread Jorge Godoy
ps bool) as $_$ SELECT (($3 between $1 and $2) or ($4 between $1 and $2)); $_$ language sql; Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate

Re: [GENERAL] Why overlaps is not working

2006-11-09 Thread Jorge Godoy
give correct results ? It might give you false positives... 2006-11-30 -- 2006-12-05 AND2006-12-06 -- 2006-12-15 (original) -- FALSE 2006-11-29 -- 2006-12-06 AND2006-12-05 -- 2006-12-16 (changed) -- TRUE Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]>

Re: [GENERAL] Can PostgreSQL notify a client that a trigger has fired?

2006-11-09 Thread Jorge Godoy
"Bill" <[EMAIL PROTECTED]> writes: > Jorge Godoy wrote: > >> I have the impression that you're missing a lot of sections in the >> manual... How about some time to re-read it? > > I don't know about you but for me a 1500 page manual is at l

Re: [GENERAL] Can PostgreSQL notify a client that a trigger has fired?

2006-11-08 Thread Jorge Godoy
; raise client event I have the impression that you're missing a lot of sections in the manual... How about some time to re-read it? http://www.postgresql.org/docs/8.1/interactive/sql-notify.html -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)

Re: [GENERAL] Isolation / Visibility inside a trigger

2006-11-03 Thread Jorge Godoy
Martijn van Oosterhout writes: > On Fri, Nov 03, 2006 at 10:24:21AM -0300, Jorge Godoy wrote: >> But then, the answer to my question is that even inside the same transaction >> or receiving the NEW row those functions called by the trigger shouldn't see >> the inform

Re: [GENERAL] Isolation / Visibility inside a trigger

2006-11-03 Thread Jorge Godoy
n, the answer to my question is that even inside the same transaction or receiving the NEW row those functions called by the trigger shouldn't see the information. Did I get it right? Thanks Martijn! -- Jorge Godoy <[EMAIL PROTECTED]> pgpuxBZdb6n9U.pgp Description: PGP signature

[GENERAL] Isolation / Visibility inside a trigger

2006-11-03 Thread Jorge Godoy
BEGIN; SET TRANSACTION ISOLATION LEVEL READ COMMITTED; Any hints would be greatly appreciated. Thanks in advance, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [GENERAL] plpython

2006-10-27 Thread Jorge Godoy
eted version ? I hope never, otherwise we loose some facilities. You understood the concept of 'safe' and 'unsafe' in PostgreSQL's docs, right? It might not be what you're thinking. Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]>

Re: [GENERAL] Database users Passwords

2006-10-17 Thread Jorge Godoy
on must be linked with -lcrypt. CONFORMING TO SVID, X/OPEN, 4.3BSD, POSIX 1003.1-2001 Well... I suppose DES is not Enigma, but I may be wrong. I just quoted this "extension"

Re: [GENERAL] Database users Passwords

2006-10-17 Thread Jorge Godoy
ere's no way to decrypt it besides a brute force attack or something like that. If he's got, e.g., 10 users with strong passwords this kind of thing can take some weeks. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--

Re: RES: [GENERAL] Dates rejected

2006-10-16 Thread Jorge Godoy
that weren't updated / fixed by their administrators are showing this problem. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Versioning/updating schema

2006-10-11 Thread Jorge Godoy
rate a script that went from one situation to the other. I haven't put my hands on that to see if it really works, though... There's something that Pentaho can do (another developer told me he used it for doing that). -- Jorge Godoy <[EMAIL PROTECTED]>

Re: [GENERAL] more anti-postgresql FUD

2006-10-10 Thread Jorge Godoy
ts (I doubt that a developer who optimizes his code for MySQL and says that on his website will have read about optimizing PG and done something like that). Using PG's advanced features (specially triggers, functions and rules) will make it MUCH better than having to deal with things a

Re: [GENERAL] more anti-postgresql FUD

2006-10-10 Thread Jorge Godoy
Tom Lane <[EMAIL PROTECTED]> writes: > Some days I think database independence is a myth. I believe it is as real as Santa Claus and the Easter Bunny. All of us know that those three exist, right? :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(e

Re: [GENERAL] increment row number function question

2006-10-07 Thread Jorge Godoy
Matthew Peter <[EMAIL PROTECTED]> writes: > Hello. I need a way to return an iterator result as a column eg, > SELECT increment() as ii, some_col from some_tbl order by some_col desc limit > 50; Use a sequence for the iterator. -- Jorge Godoy &l

Re: [GENERAL] memory issues when running with mod_perl

2006-10-01 Thread Jorge Godoy
Andreas Rieke <[EMAIL PROTECTED]> writes: > It's 2.6.13-15. Thus, if we have a kernel bug, the newest known leaky > version is 2.6.13-15, whereas the oldest fixed version should be 2.6.16.27. I have a few servers with 2.6.16.21 and I don't see the problem as wel

Re: [GENERAL] using schema's for data separation

2006-09-29 Thread Jorge Godoy
as they are > released. I'd avoid modifying source code and go with either a function or view. All queries should be against those and they'd fail if the id is missing. All filtered tables should have an index on such id, of course... -- Jorge Godoy <[EMAIL PROTECTED]> --

Re: [GENERAL] Expected accuracy of planner statistics

2006-09-29 Thread Jorge Godoy
cuum et al from > messing it up. It could not touch these setting if the specific command isn't called, it could gain a new parameter "VACUUM FULL N_DISTINCT ..." to touch it (and then we probably discard the extra command / function) or it could update these settings when called with ANA

Re: [GENERAL] Documenting stored procedures and functions

2006-09-27 Thread Jorge Godoy
todoc/. It might fit my needs, with some work done with comments. :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

[GENERAL] Documenting stored procedures and functions

2006-09-26 Thread Jorge Godoy
, updates/versioning, etc. I'm starting to create some internal standard to do that and it there are any tools -- preferably multiplatform, including specially Windows and Linux -- to help with that I'd greatly appreciate any recommendations. Be seeing you, --

Re: [GENERAL] Creating a date/time search function in Postgres.

2006-09-03 Thread Jorge Godoy
rias_alterado_por_id_fkey" FOREIGN KEY (alterado_por_id) REFERENCES tg_user(id) "categorias_criado_por_id_fkey" FOREIGN KEY (criado_por_id) REFERENCES tg_user(id) vp=# SELECT id FROM categorias WHERE alterado_em BETWEEN '2006-07-30'::DATE AND '2006-08-31

Re: [GENERAL] Precision of data types and functions

2006-08-28 Thread Jorge Godoy
er > how technically superior I can show it to be. Just show them how much money they might loose with a simple bug as the one that was shown to you on the last post :-) Money speaks very loud for any manager... -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of

Re: [GENERAL] Perl language creation failed

2006-08-28 Thread Jorge Godoy
nd says nothing do > Even tried yum install perl-base* and still says nothing to do > Don't know whats going wrong To start you're not typing the command Tom said you to. Try it first. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--

Re: [GENERAL] alternative to using a sequence

2006-08-26 Thread Jorge Godoy
a field which I query then update. Any > other ideas? Take a look at http://www.varlena.com/GeneralBits/ There are some ideas there. Of course, gapless sequences perform a bit worse than sequences. There was this discussion here on the ML last week as well, so in the archives you'll

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-21 Thread Jorge Godoy
notably slow. > > --elein > [EMAIL PROTECTED] Thanks for the article! It will be really helpful since GeneralBits is a reference point for PostgreSQL users! :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-17 Thread Jorge Godoy
ot; (employee, invoice, etc.) the operation is done only by one person and consequently in one transaction only, what makes it possible to adopt more complex -- and badly performant -- solutions (not that I want them, it's just that it wouldn't be noticeable in the application as far as the

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-17 Thread Jorge Godoy
n we have to live with it. > I may publish the gapless sequence technique on general bits if there is no > discrepancy in the understanding of the status of the second transaction's > row value (updated). I need more testing here. But from what I tested

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-17 Thread Jorge Godoy
rent from mine -- better, in fact... ;-) -- and I could give it a try. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-14 Thread Jorge Godoy
Harald Fuchs <[EMAIL PROTECTED]> writes: > In article <[EMAIL PROTECTED]>, > Jorge Godoy <[EMAIL PROTECTED]> writes: > >> Harald Fuchs <[EMAIL PROTECTED]> writes: >>> Why putting gapless numbers into the database at all? Just calculate them >&g

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-14 Thread Jorge Godoy
em everytime you need to recover some of those is something that doesn't look efficient to me... -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-14 Thread Jorge Godoy
have an after trigger I believe I wouldn't need any locking... I have to think about this... As simple as this might be, I haven't thought about it :-) Thanks for your suggestion. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-14 Thread Jorge Godoy
dex usage now happens automatically. Thanks Michael! This is great. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-14 Thread Jorge Godoy
ons this query wouldn't use an index: > select max(id) from table; It doesn't. You'd have to do what you did: "order by desc limit 1" to have it using indexes... > I'm not sure about 8.0+.. hence doing an order by the id desc limit 1. I als

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-13 Thread Jorge Godoy
lusive lock to get the value while inside the transaction? This approach seems more complicated since I'd have to exclude records that match the "not-used" pattern. -- Jorge Godoy <[EMAIL PROTECTED]> pgpZdM9XmH3t6.pgp Description: PGP signature

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-13 Thread Jorge Godoy
action fail. Theoretically, all should go fine, but... :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-13 Thread Jorge Godoy
Jorge Godoy <[EMAIL PROTECTED]> writes: > Is there a better way to guarantee that there will be no gaps in my sequence > if something goes wrong with my transaction? >From the overwhelming feedback I assume there isn't a better way yet... Thanks. I'll see how I can

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-12 Thread Jorge Godoy
t;False" instead (I can set it manually or let the RULE do that for me...). -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail com

Re: [GENERAL] Best approach for a "gap-less" sequence

2006-08-12 Thread Jorge Godoy
uot; in a 'previous' (numerically-wise) entry. Concurrency is a problem since there might be a lot of people using it. I wanted to see if there was something that could improve performance here or to solve the problem in a better way without locking the

[GENERAL] Best approach for a "gap-less" sequence

2006-08-11 Thread Jorge Godoy
in my sequence if something goes wrong with my transaction? -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Practical maximums

2006-08-07 Thread Jorge Godoy
ple tapes, tar will ask you for the next and all of them will be /dev/st. -- Jorge Godoy <[EMAIL PROTECTED]> pgpbKDmeMLX8T.pgp Description: PGP signature

Re: [GENERAL] Ajax/PostgreSQL

2006-08-05 Thread Jorge Godoy
This way all your logic is contained within PG and PHP. JS would only be used to manipulate the interface. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [GENERAL] encoding bug or feature?

2006-07-10 Thread Jorge Godoy
27;on' VERBOSITY = 'default' PROMPT1 = '%/%R%# ' PROMPT2 = '%/%R%# ' PROMPT3 = '>> ' DBNAME = 'test' USER = 'godoy' PORT = '5432' ENCODING = 'UTF8' HISTSIZE = '500' test=# Try creating a database w

Re: [GENERAL] US Telephone Number Type

2006-07-10 Thread Jorge Godoy
ange something it looks easier. Writing a function or view to retrieve the information the way you need it is also an option. Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org

Re: [GENERAL] encoding bug or feature?

2006-07-10 Thread Jorge Godoy
marcelo Cortez <[EMAIL PROTECTED]> writes: > folks > > > select ucase( 'ñ'); -> 'ñ' > i want this statemen return 'Ñ' > any ideas? test=# select upper( 'ñ'); upper --- Ñ (1 record) test=# Maybe your lo

Re: [GENERAL] Version/Change Management of functions?

2006-07-07 Thread Jorge Godoy
> "after" data dictionaries. If the changes are all valid, build the code. Ken, could you explain it a bit better? I think this is an interesting idea. -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] graph plottin engines compatible with postgres

2006-06-27 Thread Jorge Godoy
pl/R you can make a SELECT to something that will output the graphic itself :-) -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [GENERAL] Question concerning arrays

2006-06-27 Thread Jorge Godoy
the form of key=value (conc=measured), both numeric and in variable quantities for each specific test (minimum of 3, maximum of ... I don't know :-)). -- Jorge Godoy <[EMAIL PROTECTED]> ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Changing array subscripting to zero-offset

2006-06-22 Thread Jorge Godoy
ial position of the array. I also use a language where zero is the first position of the array. But if the behavior is changed, what to do with people that use languages where 1 is the first position of the array? I believe that we can't please everyone, so.

<    1   2   3   >