Skip to content

Instantly share code, notes, and snippets.

View raj-arun's full-sized avatar
🎶
Focusing

Arun Raj raj-arun

🎶
Focusing
View GitHub Profile
@raj-arun
raj-arun / ImportDataSlice.json
Created February 24, 2023 05:18
JSON Payload to Import Data using Oracle EPM Import Data Slice REST API
{
"aggregateEssbaseData": true,
"dataGrid": {
"rows": [
{
"headers": [
"OFS_Salaries"
],
"data": [
"110.00",
@raj-arun
raj-arun / exportDataSlice.json
Created September 28, 2021 04:29
EPM REST API Export Data Slice Example
{
"exportPlanningData": false,
"gridDefinition": {
"suppressMissingBlocks": true,
"pov": {
"dimensions": [
"Movement",
"Years",
"Period",
"Data Source",
@raj-arun
raj-arun / export_data_slice_param.txt
Created September 28, 2021 00:57
epm export data slice parameters
+------------------------+-------------------------------------------+
| Name | Description |
+------------------------+-------------------------------------------+
| gridDefinition | JSON grid definition to define the region |
| exportPlanningData | True or false. Default is False |
| suppressMissingBlocks | True or false. |
| suppressMissingRows | True or false. |
| suppressMissingColumns | True or false. |
+------------------------+-------------------------------------------+
@raj-arun
raj-arun / OTBI_Fetch_Next.xml
Created April 6, 2021 02:22
Fetch Next set of records from OTBI
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v7="urn://oracle.bi.webservices/v7">
<soapenv:Header/>
<soapenv:Body>
<v7:fetchNext>
<v7:queryID>RSXS8_1</v7:queryID>
<v7:sessionID>kqit1vtind5f48rl5tmlgeqois397go92iic5nrgl8litlfs</v7:sessionID>
</v7:fetchNext>
</soapenv:Body>
</soapenv:Envelope>
@raj-arun
raj-arun / OTBI_Xmlquery.xml
Created April 6, 2021 02:16
Execute OTBI Query
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v7="urn://oracle.bi.webservices/v7">
<soapenv:Header/>
<soapenv:Body>
<v7:executeXMLQuery>
<v7:report>
<v7:reportPath>/shared/custom/AR/Customers</v7:reportPath>
<v7:reportXml>?</v7:reportXml>
</v7:report>
<v7:outputFormat>?</v7:outputFormat>
<v7:executionOptions>
@raj-arun
raj-arun / OTBI_Login.xml
Created April 6, 2021 02:12
Login and Create a Session using SAWSessionService
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v7="urn://oracle.bi.webservices/v7">
<soapenv:Header/>
<soapenv:Body>
<v7:logon>
<v7:name>username</v7:name>
<v7:password>password</v7:password>
</v7:logon>
</soapenv:Body>
</soapenv:Envelope>
@raj-arun
raj-arun / OTBI_WS.csv
Last active April 6, 2021 02:09
OTBI Web Services
Method Service Description
logon SAWSessionService Login and create a session
executeXMLQuery XmlViewService Execute Query
fetchNext XmlViewService Fetch next set of records
@raj-arun
raj-arun / epm_sendmail.py
Last active April 5, 2021 19:57
Send Email from EPM using sendmail REST API
import requests
url = "https://hostname/interop/rest/v1/services/sendmail"
payload='to=user%40example.com&subject=Email%20from%20REST%20API&body=some%20body%20test&attachments=Metadata.xlsx'
headers = {
'Authorization': 'Basic YTY2ODE5NC5BcnVuLlN1cmVuZHJhbkBiYWtlcnRpbGx5LmNvbTpWY2lfYXJjc18wMDc=',
'Content-Type': 'application/x-www-form-urlencoded'
}
SELECT
TDS.NAME DATA_SOURCE_NAME
, TDS.DYNAMIC_TABLE_NAME
, 'C_'||TDSA.DATA_SOURCE_ATTRIB_ID COLUMN_NAME
FROM
TM_DATA_SOURCE TDS
, TM_DATA_SOURCE_ATTRIB TDSA
WHERE
TDS.RECON_TYPE_ID = TRT.RECON_TYPE_ID
AND TDSA.DATA_SOURCE_ID = TDS.DATA_SOURCE_ID
@raj-arun
raj-arun / get_data_source.sql
Last active January 16, 2021 16:58
get_data_source.sql
SELECT
TRT.NAME MATCH_TYPE_NAME
, TDS.NAME DATA_SOURCE_NAME
, TDS.DYNAMIC_TABLE_NAME
FROM
TM_DATA_SOURCE TDS
,TM_RECON_TYPE TRT
WHERE
TDS.RECON_TYPE_ID = TRT.RECON_TYPE_ID
AND UPPER(TRT.NAME) = UPPER(<Match Type Name>)