Comments (12)
options.verbose = True
设置这个之后,再运行这个 %%sql ,把 logview 地址贴出来看下。
from aliyun-odps-python-sdk.
同样的报错,没有logview
from aliyun-odps-python-sdk.
project 是什么?
from aliyun-odps-python-sdk.
yxjr_tmp
from aliyun-odps-python-sdk.
把 sql 写成字符串,然后用
print(repr(sql))
o.execute_sql(sql)
看下结果
from aliyun-odps-python-sdk.
'select * from llb_tp1 a left join llb_tp2 b on a.block_log_id=b.block_log_id'
NoSuchObject Traceback (most recent call last)
in ()
1 sql="select * from llb_tp1 a left join llb_tp2 b on a.block_log_id=b.block_log_id"
2 print(repr(sql))
----> 3 o.execute_sql(sql)
c:\python27\lib\site-packages\odps\core.pyc in execute_sql(self, sql, project, priority, running_cluster, hints, **kwargs)
707 inst = self.run_sql(
708 sql, project=project, priority=priority, running_cluster=running_cluster,
--> 709 hints=hints, **kwargs)
710 if not async:
711 inst.wait_for_success()
c:\python27\lib\site-packages\odps\core.pyc in run_sql(self, sql, project, priority, running_cluster, hints, aliases, **kwargs)
760 return project.instances.create(task=task, priority=priority,
761 running_cluster=running_cluster,
--> 762 create_callback=on_instance_create)
763
764 def list_volumes(self, project=None, owner=None):
c:\python27\lib\site-packages\odps\models\instances.pyc in create(self, xml, job, task, priority, running_cluster, headers, create_callback)
139 headers['Content-Type'] = 'application/xml'
140 url = self.resource()
--> 141 resp = self._client.post(url, xml, headers=headers)
142
143 location = resp.headers.get('Location')
c:\python27\lib\site-packages\odps\rest.pyc in post(self, url, data, **kwargs)
140 def post(self, url, data, **kwargs):
141 data = utils.to_binary(data, encoding='utf-8') if isinstance(data, six.string_types) else data
--> 142 return self.request(url, 'post', data=data, **kwargs)
143
144 def put(self, url, data, **kwargs):
c:\python27\lib\site-packages\odps\rest.pyc in request(self, url, method, stream, **kwargs)
132 # Automatically detect error
133 if not self.is_ok(res):
--> 134 errors.throw_if_parsable(res)
135 return res
136
c:\python27\lib\site-packages\odps\errors.pyc in throw_if_parsable(resp)
68
69 if e is not None:
---> 70 raise e
71
72 if resp.status_code == 404:
NoSuchObject: NoSuchObject: RequestId: 59B8E3966FF1A6CC3D23426F
ODPS-0130161:Parse exception - line 1:24 cannot recognize input near 'left' 'join' 'llb_tp2' in join type specifier
from aliyun-odps-python-sdk.
NoSuchObject 啊
llb_tp1 和 llb_tp2 存在吗
from aliyun-odps-python-sdk.
有啊 直接在odps就可以执行
from aliyun-odps-python-sdk.
print(o.get_table('llb_tp1').schema)
print(o.get_table('llb_tp2').schema)
结果给我看
from aliyun-odps-python-sdk.
odps.Schema {
block_log_id bigint
}
odps.Schema {
block_log_id bigint
id_no string
}
from aliyun-odps-python-sdk.
建议你开个工单,让查下什么原因导致的。
我这里建同样 schema 的表,跑没有任何问题。
In [18]: o.create_table('llb_tp1', 'block_log_id bigint')
Out[18]:
odps.Table
name: test_pyodps_dev.`llb_tp1`
schema:
block_log_id : bigint
In [19]: o.create_table('llb_tp2', 'block_log_id bigint, id_no string')
Out[19]:
odps.Table
name: test_pyodps_dev.`llb_tp2`
schema:
block_log_id : bigint
id_no : string
In [20]: %%sql
...: select * from llb_tp1 a left join llb_tp2 b on a.block_log_id=b.block_l
...: og_id
...:
|==========================================| 1 / 1 (100.00%) 12s
Out[20]:
Empty DataFrame
Columns: [block_log_id, block_log_id2, id_no]
Index: []
from aliyun-odps-python-sdk.
好的 谢谢
from aliyun-odps-python-sdk.
Related Issues (20)
- Setup odps.sql.hive.compatible=true on sqlalchemy queries HOT 1
- 'Column' object has no attribute 'join' HOT 1
- SAWarning: Dialect odps:rest will not make use of SQL compilation caching as it does not set the 'supports_statement_cache' attribute to ``True``. HOT 1
- OSError: [Errno 22] Invalid argument HOT 4
- udtf中无法读取zip资源 HOT 1
- 导入ODPS时发生错误OSError: [Errno 22] Invalid argument HOT 2
- 写数据时报错 AttributeError: 'memoryview' object has no attribute 'encode' HOT 1
- http.client.ResponseNotReady raised in 0.11.4 HOT 4
- bug in pyodps join
- 使用pyodps-pack打包第三方包的时候,加--exclude参数就会报错 HOT 2
- 本地使用pyodps包会报错:TypeError: Object of type bytes is not JSON serializable HOT 5
- Support sqlalchemy version 2 HOT 2
- 如何利用非docker模式打包依赖包 HOT 2
- 使用table.open_reader读到partition字段为None HOT 3
- 如何更新字段注释 HOT 1
- py3.11
- superset 3.x integration error HOT 2
- "decimal.InvalidOperation": 写入到本地mysql 数据表失败 HOT 1
- DataFrame.persist fail in Python3.9 HOT 2
- 什么时候能支持python3.12呀
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aliyun-odps-python-sdk.