Re: [SQL] distinguishing identical columns after joins

2011-03-02 Thread S G
> I don't suppose > there's a way to do this with functions that define multiple OUT > parameters in lieu of a custom composite type? Just had to dig a little further. Found my own answer in INFORMATION_SCHEMA.PARAMETERS. Though I wish the specific_name column didn't have that integer tagged at

Re: [SQL] distinguishing identical columns after joins

2011-03-02 Thread S G
>> But I still wonder it isn't a receiver/UI issue.  Does your reader know >> the meaning of "a_" vs "b_" in a non-trivial self join?  Wouldn't you >> rather have the output as a_col1, b_col1, a_col2, b_col2 ... for easy >> comparison.  And who can make sense of a 100 column results set anyway?:)

Re: [SQL] distinguishing identical columns after joins

2011-03-01 Thread S G
On Tue, Mar 1, 2011 at 2:53 PM, Rob Sargent wrote: > > > On 03/01/2011 12:47 PM, S G wrote: >> This question is particularly geared towards self-joins, but can apply >> to any join where the tables involved have any identical column names. >>  Aside from explicit colu

[SQL] distinguishing identical columns after joins

2011-03-01 Thread S G
This question is particularly geared towards self-joins, but can apply to any join where the tables involved have any identical column names. Aside from explicit column references, is there any way to pull all columns (*) from each table in a join and quickly append/prepend some identifier to dist