473,386 Members | 1,810 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

How to proceed

375 256MB
Hi,

I have a table in sql server as follows charges

flag monthlycharges

1 10

2 30

3 40

and so on

I will be selecting all the details of the stock from another table called as stock

idno R1 R2 R3

1 0 1 1

2 1 0 0

3 0 0 1



Here idno is the primary key, this product has 3 features R1, R2 and R3.

If the features has the value as 1 then it means the feature is activated and I will charge the client for that

The charges are specified in the table as 1,2 and 3 for the features R1,R2 and R3 respectively.

Now I take up all the records from the second table i.e. stock and populate into a datatable

I can also find out how many features are supported by the idno.

Now how to I charge this idno, because I cannot populate the charges table

it will run somewhat like this

Expand|Select|Wrap|Line Numbers
  1. for (int i=0;i<dt.rows.count;i%2B%2B)
  2.  
  3. {
  4.  
  5. double r1=convert.todouble(dt.rows[i][0].tostring));
  6.  
  7. }
In such a case only the last value will be taken up



Can anyone please throw some light on this.



Regards
cmrhema
Jan 23 '08 #1
1 950
radcaesar
759 Expert 512MB
Can you please brief on what u want to do ?

After ur definistion on the 2 tables, i was not clear on the requirement.

Send the clear table structure with exact requirement.

See u soon.
Jan 23 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: sanjay | last post by:
When I try installing fatwire CS on a trail version of Weblogic application server, installation fails. During the initial framework installation process csinstall.bat will ask to select the...
5
by: db2sysc | last post by:
All: This is becoming a big problem for us. Whenever we are using control center it asks for the userid/passwd and when we provide the admin userid/passwd we get a error "Administrative...
10
by: WindAndWaves | last post by:
Hi Gurus Whenever I start making changes in VB (without having anything open), the first time after opening the application, i will get the following error: This will reset your project do you...
3
by: James Hunter Ross | last post by:
Friends, we are using ADPlus (CDB) to log w3wp.exe things are part of our debugging efforts. A log file gets filled with TONS of "1st chance AccessViolation" exceptions. Is this to be expected? ...
1
by: Jeff User | last post by:
Hello all I need to build a web form that will allow user to enter database table column definitions. Each row on the form would contain column name, data type (chosen from a drop down list), size...
2
by: Jeff User | last post by:
Hello all I need to build a web form that will allow user to enter database table column definitions. Each row on the form would contain column name, data type (chosen from a drop down list), size...
6
by: aa | last post by:
Is there a limitation of the number of recordsets ASP is able to proceed? When my Access database exceeded 544 records, only first 544 records are shown
2
by: Steve K | last post by:
I got a bit of a problem I like some help on. I'm designing an online training module for people that work in food processing plants. This is my target audience. These workers have little or no...
1
by: jmar | last post by:
I posted on this topic a while back and received some good responses. However, I have better insight into what I'm looking to do so I am tapping the wealth of experience here again hoping to find a...
1
by: -Lost | last post by:
Unsure of how to proceed -- Windows Explorer plugin/add-in. I want to develop a Windows Explorer add-in that adds an additional listing to the "Views" button and then modify the "contents" of the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.