Best Approach to data storage in memory

S

Simon Whale

Hi,

using VB.NET i have the following design / implementation issue.

We're designing an insurance underwriting project, which i describe a bit in
english

For every insurance policy there could be an undetermined number of
properties to the policy (for example property investors etc).

my question is what would be the best way to store these in memory before
commiting them to the database while performing business logic.

My question is what would be best for editing entries? List(of t) or
datatable?

Many thanks for your help

Simon
 
G

Gregory A. Beamer

My question is what would be best for editing entries? List(of t) or
datatable?

The list is lighter weight, so, if it is prudent, I would head that
direction. But, there are factors that may make the list an issue.

For example, if the list is rarely edited before committing, then making
editing easier is not your primary concern. The primary concern is
reducing errors on saving and using the most maintainable code possible.
In this instance, the DataTable might be better, especially if you use
TableAdapters to commit data.

What you have to look at is the most common path combined with
maintainability. That is first run. Then, see if there are any other
issues , like performance, that makes you rethink your chosen path.

One more thing to think of. If you are using the built in CRUD
methdology with DataSets, you end up with a translation "layer" for your
entries to turn them into a List(of T) and back. This is one potential
source of error. I am not saying avoid this, but ask your motivation
before you introduce this extra "complexity" into the app.

Peace and Grace,
Greg

--
Vote for Miranda's Christmas Story
http://tinyurl.com/mirandabelieve

Twitter: @gbworld
Blog: http://gregorybeamer.spaces.live.com

*******************************************
| Think outside the box! |
*******************************************
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top