Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/user-interface/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 3.x Oracle查询提供“ORA-00911:无效字符”_Python 3.x_Pandas_Oracle_Cx Oracle - Fatal编程技术网

Python 3.x Oracle查询提供“ORA-00911:无效字符”

Python 3.x Oracle查询提供“ORA-00911:无效字符”,python-3.x,pandas,oracle,cx-oracle,Python 3.x,Pandas,Oracle,Cx Oracle,您好,我正在尝试执行以下Oracle查询。我确认我可以使用cx_Oracle成功连接到数据库,但我的查询未执行。这是一个很大的表,我试图将行数限制为10行 query1 = """ select * from (select * from some_table ) where rownum < 10; """ df_ora1 = pd.read_sql(query1, con=connection1) 我得到以

您好,我正在尝试执行以下Oracle查询。我确认我可以使用cx_Oracle成功连接到数据库,但我的查询未执行。这是一个很大的表,我试图将行数限制为10行

query1 = """
select *
  from
(select *
   from some_table
  )
where rownum < 10;
""" 

df_ora1 = pd.read_sql(query1, con=connection1)
我得到以下错误,但无法找出无效字符是什么

数据库错误:ORA-00911:无效字符


请帮忙

从SQL语句中删除分号。分号不是SQL的一部分

query1 = """ select * from (select * from some_table ) where rownum < 10 """