Skip to content

Make use of ROWSKIPS and ROWCOUNT of RFC_READ_TABLE #5

@gllrt

Description

@gllrt

Two currently unused options of RFC_READ_TABLE are ROWSKIPS and ROWCOUNT. A possible way to incorporate them into RSAPReadTable is:

RSAPReadTable <- function(con, saptable, options=list(), delimiter=';', skip=0, n=-1L, fields=list())
{
  if(!RSAPValidHandle(con))
    stop("argument is not a valid RSAP con")
  library(reshape)
  parms <- list('DELIMITER' = delimiter,
                'QUERY_TABLE' = saptable,
                'OPTIONS' = list('TEXT' = options),
                'FIELDS' = list('FIELDNAME' = fields),
                'ROWSKIPS' = skip
  )
  if (n != -1L){
    parms[['ROWCOUNT']] <- n
  }
...

One has to bear in mind though that depending on the NW RFC version there could be limits on these based on their types - I've read of instances where ROWSKIPS is INT4 and thus limited to 999999. The version that is available to me does not seem to impose such restrictions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions