Re: [GENERAL] Request for review of new redis-fdw module

2015-01-28 Thread George Silva
Great. Congratulations. How big is the latency in the FDW? This opens up new possibilities using redis. Very cool. On Wed, Jan 28, 2015 at 5:19 PM, Leon Dang wrote: > > Andreas Kretschmer wrote on 01/28/2015 03:36 AM: > >> > I've implemented a completely new Redis FDW module which has little to

Re: [GENERAL] Finding the primary key of tables

2010-08-03 Thread George Silva
Thanks a million. Rusty SQL :P 2010/8/3 Merlin Moncure > 2010/8/3 George Silva : > > I'm going for Merlin's solution. Its the easiest one :P > > > > But I'm also having a problem: > > > > SELECT column_name FROM information_s

Re: [GENERAL] Finding the primary key of tables

2010-08-03 Thread George Silva
ble_name) WHERE table_constraints.constraint_type = 'PRIMARY KEY' AND k.table_name = 'acidentes' AND k.table_schema = 'public' this still returns me multiple columns. Did I forgot something? 2010/8/3 Devrim GÜNDÜZ > On Tue, 2010-08-03 at 16:13 -0300, George Silva wrote: >

[GENERAL] Finding the primary key of tables

2010-08-03 Thread George Silva
Hello guys, I'm building a function which needs to know what is the primary key of a certain table (all in pgplsql). I was using select * from information_schema.key_column_usage where table_schema='foo' and table_name = 'aaa'; but that will give me multiple results in case of additional keys in

Re: [GENERAL] Fuzzy string matching of product names

2010-04-05 Thread George Silva
The above is true. For geocoding the same idea is used: the metaphone function is used against street names, and searched to a simples column, filled with the results of the metaphone function. It works quite well. George On Mon, Apr 5, 2010 at 4:23 PM, Brian Modra wrote: > On 05/04/2010, Peter

[GENERAL] Rules, triggers and such

2009-12-09 Thread George Silva
Hello all again :) I have a question: is it possible to replicate the behavior of a rule INSTEAD of with a TRIGGER? For some specific reasons i need to use a trigger to update a secondary table, but i don't want the changes to happen in the primary table too. Is it possible to do it? If so, how?

Re: [GENERAL] Rules and conditions

2009-12-09 Thread George Silva
WHERE oid = new.oid; WHEN a=false THEN INSERT INTO versioning.foo_version_1(NEW.*,'UPDATE'); END ); Any thoughts? Thanks On Wed, Dec 9, 2009 at 8:56 AM, George Silva wrote: > Thanks guys for clearing my head. > > George > > On Wed, Dec 9,

[GENERAL] Rules and conditions

2009-12-08 Thread George Silva
Hello guys, I can't seem to understand why a simples if is not working on the creation of rules. I tried both ways (am i missing something?): Take a look: CREATE OR REPLACE RULE instead_update AS ON UPDATE TO foo DO INSTEAD ( IF exists(SELECT 1 FROM versioning.foo_version_1 WHERE oid =