Forum Discussion
ckattookaran
2 years agoVIP
Yes and no, you can create a buffer with existing data only. Now once you have that anchor you can loop through those cells and get stuff from the members that are there in the buffer. You can then create a new buffer and while looping through your anchor you can change the account and other members of the result databuffer cell and save it.
Not sure if that is what you are looking for.
- Gidon_Albert2 years agoContributor II
Right. So the problem is that the initial data buffer does not generate any cells because there are no cells with data. In other words, the anchor is empty so there is nothing to loop through.
- JackLacava2 years agoHonored Contributor
Yes. A different approach, starting from scratch, should work but it's very low level and somewhat tedious. This is a rought start that should work (not tested...
'create a new PK for each cell, describing the intersection Dim newPk As New DataBufferCellPk() newPk.AccountId = api.Members.GetMemberId(dimtype.Account.id, "myacc") newPk.FlowId = api.Members.GetMemberId(dimtype.Flow.Id, "myflow") '... set all dimensions ... ' create a new cell with the pk. There are other constructors too. Dim newCell As New DataBufferCell(newPk, 10.0, DataCellStatus.CreateDataCellStatus(False, False)) ' create the buffer, put cell(s) in it Dim newBuffer As New DataBuffer() newBuffer.SetCell(si, newCell) ' trigger saving to database Dim dest As ExpressionDestinationInfo = api.Data.GetExpressionDestinationInfo("") api.Data.SetDataBuffer(newBuffer, dest)
Related Content
- 6 months ago
- 2 years ago
- 3 years ago
- 11 months ago