Skip to Content
author's profile photo Former Member
Former Member

How to convert database field to array

Hi All,

I want to convert data base field(string or date field) to array field. my source is BW . How can we do this if any one know how to do Please help me.



Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Jan 27, 2014 at 10:18 AM

    Hi Ambreen,

    What do you wish to do with the array variable?

    Here's how we do it:

    1) Create a formula with the code below and place it on the Details Section:


    stringvar array arr;

    numbervar x := x + 1;

    redim preserve arr[x];

    arr[x] := {Database_String_field};

    The above formula assigns values to the array variable 'arr'.

    2) The array variable can then be used on any section 'below' the Details Section. Group Footer/Report Footer

    3) To display the values of the array as a comma separated string on the Report Footer, create another formula with the code:


    stringvar array arr;

    Join(arr, ", ");

    4) For a Date field, create a Datevar Array similar to the first formula, however you can't use the second formula to display the dates as a comma separated string. You would need to convert each value in the array to a string and then display it.

    Hope this helps.


    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 27, 2014 at 10:27 AM

    Hi Ambreen,

    Check below link


    Add a comment
    10|10000 characters needed characters exceeded

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 you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.