JCo RFC_READ_TABLE 数据缓冲区超出 [英] JCo RFC_READ_TABLE Data Buffer Exceeded

查看:42
本文介绍了JCo RFC_READ_TABLE 数据缓冲区超出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试通过函数 RFC_READ_TABLE 从表 VBRK 中获取数据,但总是收到数据缓冲区超出异常.

i'm trying to get data from Table VBRK via Function RFC_READ_TABLE but always getting a Data Buffer Exceeded Exception.

final JCoConnection managedConnection2 = sapCoreJCoManagedConnectionFactory.getManagedConnection("JCoStateless",
        getClass().getName(), rfcDestination);

final JCoFunction function2 = managedConnection2.getFunction("RFC_READ_TABLE");

final JCoParameterList importParameterList2 = function2.getImportParameterList();

importParameterList2.setValue("QUERY_TABLE", "VBRK");
final JCoParameterList tableParameterList2 = function2.getTableParameterList();

final JCoTable optionsTable = tableParameterList2.getTable("OPTIONS");
String selectionFilter = "VBELN EQ '" + "0123456789" + "'";
optionsTable.appendRow();
optionsTable.setValue("TEXT", selectionFilter);

//execute function RFC_READ_TABLE
managedConnection2.execute(function2);

有人能指出我的错误吗?

Can anybody point out my mistake?

推荐答案

您收到此错误是因为所选字段不适合结构 DATA,即 TAB512.此外,功能模块RFC_READ_TABLE 还限制读取每行数据是否超过 512 字节.

You are getting this error because selected field do not fit into structure DATA i.e TAB512. Further, Function Module RFC_READ_TABLE also limits if read exceeds 512 bytes per row of data.

您已将 OPTIONS 应用于 SELECT 记录,但您没有使用 FIELDS 限制 SELECTED 字段.如果您将限制 SELECTED 字段,那么您将不会遇到错误数据缓冲区超出.还建议使用 ROWCOUNT 限制记录数.

You have applied OPTIONS to SELECT records but you did not limit SELECTED fields using FIELDS. If you will limit SELECTED fields then you will not face error Data Buffer Exceeded. It is also recommend to limit no of records using ROWCOUNT.

这篇关于JCo RFC_READ_TABLE 数据缓冲区超出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆