Solved

update generic list with values from another generic list using multiple column join

Posted on 2013-11-15
5
377 Views
Last Modified: 2013-11-29
I have two genric lists, I need to update the vlaues in one generic list with values fom another

List1
ID
DATE
Return


List2
ID
DATE
Value

There could be no values for List1 in list2 but I need to get default or empty values
0
Comment
Question by:countrymeister
  • 3
  • 2
5 Comments
 
LVL 15

Expert Comment

by:unknown_routine
ID: 39652159
How did you define these lists? are these both list of Strings?
0
 
LVL 1

Author Comment

by:countrymeister
ID: 39652215
ID int
Date datetime
Value decimal


ID int
Date DateTime
Return decimal
0
 
LVL 15

Accepted Solution

by:
unknown_routine earned 500 total points
ID: 39659681
You can not put different types inside a "generic list".

By Generic, do you refer to a Generic list? For example:


 Dim lstItems As List(Of String) = New List(Of String)


You can however create a class with ID, Date, Value as its properties and add it to a generic list.

Please clarify your question.
0
 
LVL 1

Author Comment

by:countrymeister
ID: 39660489
Maybe I did not put my question more clearly.
I need to update values in one list based on the values in the other

The ID is the join field and so is the Date, I want to update the Value field with that of the return
0
 
LVL 1

Author Closing Comment

by:countrymeister
ID: 39686089
Could not understand my question and did not povide a good solution
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question