On 20-10-2016 12:37, Kovalenko Dmitry wrote: > Firebird 2.5.x can prepare SQL like “select (x.*) from MYTABLE x” > > Firebird 3.0.2.32619 returns the error: > > Dynamic SQL Error > SQL error code = -104 > Token unknown - line 1, column 11 > * > > It is regression or FB2.5 works incorrectly?
I have no idea what (x.*) would have to mean, especially when you consider row value constructors. Parenthesis around single elements are single-valued row values, Firebird currently does not support n-valued row values, but the standard specifies that you need to be explicit about columns in a row value, so (x.*) is not a valid row value constructor (and even if it were: Firebird doesn't support n-valued row values). The standard only allows a 'qualified' asterisk in a non-parenthised context. The SQL standard derivation is: <select list> ::= <asterisk> | <select sublist> [ { <comma> <select sublist> }... ] <select sublist> ::= <derived column> | <qualified asterisk> <derived column> ::= <value expression> [ <as clause> ] <value expression> ::= <common value expression> | <boolean value expression> | <row value expression> <---- see 7.1 and 7.2 of SQL:2011 Foundation <qualified asterisk> ::= <asterisked identifier chain> <period> <asterisk> | <all fields reference> <asterisked identifier chain> ::= <asterisked identifier> [ { <period> <asterisked identifier> }... ] <asterisked identifier> ::= <identifier> <all fields reference> ::= <value expression primary> <period> <asterisk> [ AS <left paren> <all fields column name list> <right paren> ] -- Mark Rotteveel ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel