List:Internals« Previous MessageNext Message »
From:Paul DuBois Date:March 4 2003 12:40am
Subject:Re: MYSQL_FIELD->name containing "table.field"
View as plain text  
At 0:29 +0000 3/4/03, Tim Bunce wrote:
>The docs for the MYSQL_FIELD structure here
>   char * name
>     The name of the field, as a null-terminated string.
>   char * table
>     The name of the table containing this field, if it isn't a
>     calculated field. For calculated fields, the table value is an
>     empty string.
>But it seems that the name element contains table.field for statements
>	SELECT table.field FROM table
>This is inconsistent with all other databases I've worked with.
>Notably it creates an ambiguity because it's not possible to tell
>if the '.' in the name field is an indentifier-separator dot, or
>a dot embedded in a field name:
>	SELECT field AS `` FROM table
>There is separate table element in the MYSQL_FIELD structure so
>including the table name in the field name is redundant.

I don't think that this has ever been true before, and if the
name field now contains the table name, I'd argue that it's
a bug that has been introduced that should be fixed.

>Before posting, please check:
>   (the manual)
>           (the list archive)
>To request this thread, e-mail internals-thread7279@stripped
>To unsubscribe, e-mail <internals-unsubscribe@stripped>

bk commit into mysqldoc treeserg10 Nov
  • MYSQL_FIELD->name containing "table.field"Tim Bunce4 Mar
    • Re: MYSQL_FIELD->name containing "table.field"Paul DuBois4 Mar
      • Re: MYSQL_FIELD->name containing "table.field"Tim Bunce4 Mar