Re: How to extract a value from a record using attnum or attname?
Kevin Grittner <kevin.grittner@wicourts.gov>
From: "Kevin Grittner" <Kevin.Grittner@wicourts.gov>
To: "Alvaro Herrera" <alvherre@commandprompt.com>
Cc: "Dimitri Fontaine" <dimitri@2ndquadrant.fr>, "Andrew Dunstan" <andrew@dunslane.net>, "pgsql-hackers" <pgsql-hackers@postgresql.org>
Date: 2011-02-23T19:20:16Z
Lists: pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> wrote: > Why not use quote_identifier and quote_literal_cstr instead of > this new strcpy thing? We've got various types of software that will be parsing these payloads, and it's a little easier to parse if the quoting is unconditional. If that's a barrier to acceptance we could use the functions which quote conditionally and adjust our regular expressions. Probably one reason we had a bias toward quoting is that every single application table name we use has at least on uppercase letter and about 95% of our column names do. > Also, you don't really need spi.h do you? It's using these functions: SPI_getrelname SPI_fname SPI_getvalue If there's a better way to get the info, I'm game. -Kevin