0% found this document useful (0 votes)
4 views

Writing Custom Data Into Tables

Writing custom data into tables

Uploaded by

ARPITA BISWAS
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views

Writing Custom Data Into Tables

Writing custom data into tables

Uploaded by

ARPITA BISWAS
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

1/6/24, 9:40 AM Writing custom data into tables | SAP Community

Community

 Mark Your Calendars 


Mark Your Calendars with these Here’s what you need to know to prepare.
Important Dates. SAP Community is
moving in January 2024!

Ask a Question Write a Blog Post Login

Search Questions and Answers

Krzysztof Korościk
Nov 26, 2020 at 09:18 AM

Writing custom data into tables


838 Views | Last edit Nov 26, 2020 at 09:30 AM | 2 rev
1

Follow RSS Feed

Hello!

Wanted to ask - is it possible to write data into tables in SAC Analytic Designer?

For example, I added an empty column next to actual values to a table.

Using Table.getSelection i can download the cell position without any issues. However, browsing thru Api and google i
cannon't find any functions that would allow me to put a value into that cell.

Is it all possible? Are there any walkarounds, similiar solutions?

I would appreciate every feedback.

Kind regards,

https://answers.sap.com/questions/13196502/writing-custom-data-into-tables.html 1/5
1/6/24, 9:40 AM Writing custom data into tables | SAP Community

Chris

Add a Comment | Alert Moderator

Assigned Tags

SAP Analytics Cloud, analytics designer

table

script

put

custom value in table

scri

Similar Questions 
Mass Upload Excel Transaction Data Via Analytic cloud using Custom Widget
Kamal Kaushik Sep 25, 2023

How to copy current hierarchy selection to another table


Andres Romero Nov 14, 2023

1 Answer

Sort by: Votes | Newest | Oldest

Best Answer

Vadim Kalinin
Nov 26, 2020 at 09:29 AM

Easy!
1

var selectionArr = Table_1.getSelections();


if (selectionArr.length>0)

https://answers.sap.com/questions/13196502/writing-custom-data-into-tables.html 2/5
1/6/24, 9:40 AM Writing custom data into tables | SAP Community

{
for(var i=0;i<selectionArr.length;i++)
{
var selection = selectionArr[i];
//console.log(selection.length);
var dimcount=0;
for(var dimensionId in selection)
{
dimcount++;
}
if (dimcount>1)
{
var data_cell = Table_1.getDataSource().getData(selection);
var table_value=data_cell.rawValue;
if (table_value !== "–")
{
var planning=Table_1.getPlanning();
var num_cell_value=ConvertUtils.stringToNumber(table_value);
var driver_value=ConvertUtils.stringToNumber(InputField_1.getValue())
planning.setUserInput(selection,ConvertUtils.stringToNumber((num_cell_
}
}
planning.submitData();
}
}

The mentioned code is attached to the button. It will multiply selected cells with the value contained
in InputField_1

Add a Comment | Alert Moderator | Share

 8 comments

Jef Baeyens Nov 27, 2020 at 02:38 PM

then it's correct :)

Like 0 | Share | Alert Moderator

Add a Comment Show all 

https://answers.sap.com/questions/13196502/writing-custom-data-into-tables.html 3/5
1/6/24, 9:40 AM Writing custom data into tables | SAP Community

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want
the poster to clarify the question or provide more information, please leave a comment instead, requesting
additional details. When answering, please include specifics, such as step-by-step instructions, context for
the solution, and links to useful resources. Also, please make sure that your answer complies with our Rules
of Engagement.

Rules of Engagement 

Know someone who can answer? Share a link to this question.

You must be Logged in to submit an answer.

Please provide a distinct answer and use the comment option for clarifying purposes.

10 characters required.

Submit your Answer

Find us on

Privacy Terms of Use

Legal Disclosure Copyright

Trademark

https://answers.sap.com/questions/13196502/writing-custom-data-into-tables.html 4/5
1/6/24, 9:40 AM Writing custom data into tables | SAP Community

Newsletter Support

https://answers.sap.com/questions/13196502/writing-custom-data-into-tables.html 5/5

You might also like