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

Fast way to Sum up values from an existing column(freshly entered ones too)

Hi

I'm talking from the weight column in the matrix in the Orderform.

Imho there are three possibilities to achieve this:

1. Those Select $[...]

2. More or less directly by iterating through the column objects (.specific)

3. Iterating through the DBDatasource.

I went with 2 but the performance is just annoying when formated searches comes in to play.

I don't know where to find documentation about those Select $[...] Queries so I couldn't test. Does anybody know a source?

I can somehow feel that Iterating through DBDatasources wouldn't be very fast but i am not 100% sure.

How has it to be done? Maybe somebody can point me in the right direction.

Thanks Phil

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Feb 08, 2005 at 08:36 AM

    Hi Phil,

    You have information about formatted searches in the marketplace, under Service&SupportKnowledge&ServicesKnowledge BaseCustomizingFormatted Search. There are 2 interesting documents here.

    From one of them:

    "To retrieve data from the active window a special query should be created. The SAP Business One system provides 2 different syntaxes for the query:

    · $[Tablename.Fieldname]

    Tablename – indicates the table, which the active window relates to.

    Fieldname – the field from the active window.

    · $[$Field Index. Field Column. Number/Currency/Date.0]

    This syntax uses the field’s index instead of the specific document table."

    By the way, I think you are not going to be able to calculate a Sum, becouse you cant refer to an specific row within the matrix. You can refer to the first row, or to the actual row. But not specify the row number.

    Hope helps,

    Ibai Peñ

    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.