Alias for JOIN with subquery #83
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I want to build this sql statement using xorm builder:
How to add "AS external", at the last line, using xorm query builder ?
without it, postgres will complain "subquery in FROM must have an alias"
Been trying this without no luck :
DBFiddle
I close this, using separeted query solve the problem,
In case someone has same problem this is the solution (sb is xorm query builder):
Ah, that's a workround.
I think my solution is more a "hack" than a solution :)
I propose to add optional Alias parameter into .Select() method just like existing .From() method, or maybe adding new .As() method which can be used by .Select() and .From() methods
@bandirsen I put up this PR #94 for this functionality.