RSAPReadCube: SAP RFC function calls

Description Usage Arguments Details Value Note Author(s) See Also Examples

View source: R/RSAP.R

Description

Open connections to an SAP System for RFC calls

Usage

1
RSAPReadCube(con, cube, ref_date, chars=list(), kfigures=list(), options=list())

Arguments

con

an Open SAP RFC Conneciton handle

cube

The technical name of an infocube to read

ref_date

The reference date for data selction from the infocube

chars

list of characteristic technical names that you want in the result set

kfigures

A list of key figure technical names that you want in the result set

options

A list of options and their selection criteria based on the technical names of attributes with a syntax like ABAP SELECT-OPTIONS

Details

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
  con <- RSAPConnect(ashost="nplhost", sysnr="42",
                      client="001", user="developer", 
                      passwd="developer", lang="EN", 
                      trace="1", lcheck="1")

  res <- RSAPReadCube(con, "0D_NW_T01", "20120716", 
                            chars=list("0D_NW_SORG", "0D_NW_PROD"),
                            kfigures=list("0D_NW_NETV"),
                            options=list(CHANM=list('0D_NW_SORG'),SIGN=list('I'), COMPOP=list('EQ'), LOW=list('1514')))
  # or alias
  # res <- readCube(con, ...

  print(res)

  RSAPClose(con)
  

Value

Returns a data.frame of the info cube query

Note

You can run the RSAPListCubes(con) to get a list of cubes to query. For each cube you can then run RSAPGetCube(con, '<cube name>') to get the details of the cube layout.

Author(s)

Piers Harding

See Also

RSAPConnect, RSAPGetInfo, RSAPInvoke, RSAPReadTable, RSAPClose

Examples

1
2
3
4
5
## Not run: 
# read the NW demo data info cube
  res <- RSAPReadCube(con, "0D_NW_T01", "20120716",chars=list("0D_NW_SORG", "0D_NW_PROD"), kfigures=list("0D_NW_NETV"))

## End(Not run)

RSAP documentation built on May 29, 2017, 1:47 p.m.