Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Relabel fix #1216

Merged
merged 2 commits into from
Aug 23, 2015
Merged

Relabel fix #1216

merged 2 commits into from
Aug 23, 2015

Conversation

llllllllll
Copy link
Member

Broken expression:

In [1]: ds = bz.Data(resource('postgresql://localhost/bz::ds', schema='vnd'))

In [2]: ds.dshape
Out[2]: 
dshape("""var * {
  asof_date: ?datetime,
  value: ?float64,
  symbol: ?string,
  knowledge_date: ?datetime,
  sid: ?int64
  }""")

In [3]: ds[['value', 'sid']].relabel(value='test')
Out[3]: ---------------------------------------------------------------------------
ProgrammingError                          Traceback (most recent call last)
    ...
ProgrammingError: (psycopg2.ProgrammingError) subquery in FROM must have an alias
LINE 2: FROM (SELECT vnd.ds.value AS value, vnd.ds.sid AS sid 
             ^
HINT:  For example, FROM (SELECT ...) [AS] foo.
 [SQL: 'SELECT value AS test, sid \nFROM (SELECT vnd.ds.value AS value, vnd.ds.sid AS sid \nFROM vnd.ds) \n LIMIT %(param_1)s'] [parameters: {'param_1': 11}]

llllllllll added a commit that referenced this pull request Aug 23, 2015
@llllllllll llllllllll merged commit fca1877 into blaze:master Aug 23, 2015
@llllllllll llllllllll deleted the relabel-fix branch August 23, 2015 03:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant