rforcecom.retrieve: Retrieve a record

Description Usage Arguments Value Author(s) See Also Examples

View source: R/rforcecom.retrieve.R

Description

Retrieve a record

Usage

1
2
rforcecom.retrieve(session, objectName, fields, limit=NULL, id=NULL,
                   offset=NULL, order=NULL, inverse=NULL, nullsLast=NULL)

Arguments

session

Session data. It can be retrieved from rforcecom.login.

objectName

An object name. (ex: "Account", "Contact", "CustomObject__c")

fields

A List of field names. (ex: c("Id", "Name", "Industry", "AnnualRevenue)") )

limit

Number of the records to retrieve. (ex: 5)

id

Record ID to retrieve. (ex: "999x000000xxxxxZZZ")

offset

Specifies the starting row offset. (ex: "100")

order

A list for controling the order of query results. (ex: "c("Industry","Name")")

inverse

If it is TRUE, the results are ordered in descending order. This parameter works when order parameter has been set. (Default: FALSE)

nullsLast

If it is TRUE, null records list in last. If not null records list in first. This parameter works when order parameter has been set. (Default: FALSE)

Value

Result dataset.

Author(s)

Takekatsu Hiramura <thira@plavox.info>

See Also

rforcecom.login

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
 # Retrieving a record
 objectName <- "Account"
 fields <- c("name", "Industry", "AnnualRevenue")
 rforcecom.retrieve(session, objectName, fields)
 rforcecom.retrieve(session, objectName, fields, limit = 5)
 rforcecom.retrieve(session, objectName, fields, id = "999x000000xxxxxZZZ")
 rforcecom.retrieve(session, objectName, fields)
 rforcecom.retrieve(session, objectName, fields, order = c("Industry","Name"))
 rforcecom.retrieve(session, objectName, fields, order = c("Industry","Name"),
                    inverse=TRUE, nullsLast=TRUE)
 
## End(Not run)

RForcecom documentation built on May 1, 2019, 6:31 p.m.