diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2008-02-19 23:46:14 +0000 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2008-02-19 23:46:14 +0000 |
| commit | 7f43bc55e027b6419ac5a9893515ad9581c98538 (patch) | |
| tree | 3ea6904cc8db7dcab2b6928029ae1740e90be7ac /test/sql | |
| parent | 3e6e61dbe7b13be851e78db4280565f84c874c35 (diff) | |
| download | sqlalchemy-7f43bc55e027b6419ac5a9893515ad9581c98538.tar.gz | |
- can again create aliases of selects against textual
FROM clauses, [ticket:975]
Diffstat (limited to 'test/sql')
| -rw-r--r-- | test/sql/select.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/sql/select.py b/test/sql/select.py index 39906dcdb..f64373d3a 100644 --- a/test/sql/select.py +++ b/test/sql/select.py @@ -625,6 +625,11 @@ WHERE mytable.myid = myothertable.otherid) AS t2view WHERE t2view.mytable_myid = select(["column1 AS foobar", "column2 AS hoho", table1.c.myid], from_obj=[table1]).select(), "SELECT column1 AS foobar, column2 AS hoho, myid FROM (SELECT column1 AS foobar, column2 AS hoho, mytable.myid AS myid FROM mytable)" ) + + self.assert_compile( + select(['col1','col2'], from_obj='tablename').alias('myalias'), + "SELECT col1, col2 FROM tablename" + ) def test_binds_in_text(self): self.assert_compile( |
