On 10/4/14, 8:12 PM, Robert Haas wrote:
>> >It's just not sane to try to parse such text strings.
> But this is a pretty ridiculous argument. We have an existing parser
> that does it just fine, and a special-purpose parser that does just
> that (and not all of the other stuff that the main parser does) would
> be a great deal simpler. Maybe there are examples other than the ones
> you listed here that demonstrate that this is actually a hard problem,
> but the fact that you might need to undo quote_literal() or search for
> and split on fixed strings does not.
FWIW, I've run into situations more than once in userspace where I need a way to properly separate schema and object
name.Generally I can make do using reg* casts and then hitting catalog tables, but it'd be nice if there was an easier
way.
--
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com