C# - Fetching Data From Different Table?
May 3, 2010I want to fetch data from separate tables in sqlserver and display them together in GridView, Is that possible?
View 3 RepliesI want to fetch data from separate tables in sqlserver and display them together in GridView, Is that possible?
View 3 RepliesI have one Store Procedure that generating report ..
For storing the data there , i used many temp. tables. There is many Select Query , little less insert and delete query.
Now if there is huge data around 1 lac in temp table my select query taking to much time and also may be insert and delete query
I added Primary key to all auto Increment Field in temp table. Also defined Clustered index on that primary key as unique Clustered index to improve the performance .
But there is not so much improvement in case of huge temp table.
Right now the whole Store Procedure is taking time to complete around 1.5 days or around 30 hours ..
So i want to increase the performance as much that it completes on nearly 3-4 hours.
if I have this URL:
[URL]
How can I fetch the first two information from it into my aspx page? for example I want to read the first two timings.. Should I use xmlReader or what?
1)usign execute scalar i will get 1st col and 1st row value.
2)using dataset i will get whole table.. if my stored proc has 2 queries then i will get 2 tables within same dataset.. i can reference therese using ds.tables(0).rows(value).
3)suppose i use a datareader then i will get multiple-rows. i want to know how to get these each separate rows coloumn values into variables. below is the reader aspx.vb
reader = cmd.ExecuteReader();
while (reader.Read()) {
4)what is it mean by data reader is forward only method of getting data.
5)why do we do readeritem.tostring()
6) can you tell me the basic how is this reader,ds,scalar works.i mean i know to use but donot know basics esspecially the dataadpapter.why do we fill it when using dataset.
what's the best and most likely way to fetch data from database...
View 5 RepliesData can be fetched into an application through web service can it be possible to update data in web service from our application ..
View 2 RepliesI need to do parallel processing in my coding because i have 4 sql to fetch data from database which each take me 3-4 minutes.All the tables involved are raw table and that is no way i can reduce the time for the sql.I need to find a way out to reduce the data fetching time.The only thing i canfigure out is to have this 4 sql execute at the same time by doing parallel processing.
View 4 RepliesI have a problem at the time of updating the datagrid. I want that at the time of update data is shown in form instead of datagrid.
[code]....
I have a webservice which needs to query the Database every hour to get the latest copy of the data. What would be the best way to have the websevice call a method every hour. I am condering using the imers.Interval to call a method every hour.
View 3 RepliesI have a gridview which is present inside a repeater. I have been successful in displaying the data inside the grid view. Now I want to fetch data from the gridview. But i have not been able to fetch the data from the grid view.
View 5 RepliesI have two databases (DB1 & DB2) from which i wish to build a single table/gridview output, ideally i want to be able to sort the table by using any data.
However i cannot seem to figure out how to have more than one datasource per Gridview, and if i have more than one Gridviews then i can't sort all the data by any of the columns.
This is a oneway street, i do not want to update the databases from the webfront end.
Here is a Trimmed Down Version of what i have
[code]....
I want to show processing .gif image while submitting data or fetching data?
For example,When we search for hotels in any city after clicking search we have a model popup which ask you to wait and shows processing image.
My application has GRID VIEW control, which displays, Folder Name and Folder Path. While rendering in the webpage, i want to display only the Folder Name. For this, i set the visible property to false. Now iam able to display only Folder Name column.
Now the problem is, though iam hiding the Folder path column, i want to retrieve, the Folder path, when user clicks on submit button. Iam getting empty value for the hidden column.
I am fetching data from oracle data base in asp.net application. To achieve this functionality i have used Oracle.DataAccess dll . In my developement enviorment it working fine.
But once I deployed this code on IIS 6.0 it is stopped working and I checked my log and found connection not get established . Then I make sure Oracle.DataAccess.dll present in to bin folder also I try to put this dll in side GAC, but still my code is not working on deployed server.
Lets say i'm retreiving some data or string to the server using a webservice. How can i insert a preloader?
View 3 Replies[Code]....
I have a List View lstViewAB , by the above code i m trying to find the text on the lblMobile for those which are checked (checkbox). But the problem is that the text of label lblMobile is fetched of 1,3,5 rows only and for 2,4,6 rows it shows text "".
I am able to fetch the data from LDAP localy thru bellow coding, but i am not able to fetch the data when i am this page in IIS. page is comming but there is not data here is my coding
[Code]....
I am trying to fetching the data from Book1.xlsx file. The program is not working and throws an exception. check the code and tell me where I am doing the mistake?
[Code]....
The exception is:
An error: The Microsoft Office Access database engine cannot open or write to the file ''. It is already opened exclusively by another user, or you need permission to view and write its data.
I have two tables
1. Table1
Mandli_name, latitude, longitude
2 . Table 2
Mandli_name, daily_collection, collection_date
I want to show daily collection of the mandli on the google map info window. .According to date input ....so I want to how can I fetch the data from two different table..
User enter date in the textbox and click search button that is my scenario. ..
in gridview i hv columns like
name | phno. | emp_name(in dropdown) | buttonfield
wen user comes on this page this grid comes filled but then I need to select 1 emp_name from dropdown and click button(in last column) corresponding to that row. then on clicking that row button it should fetch that toq Primary Key and dropdown corresponding id. how? Wen I m fetching its fetching row index as 0 though it is no.4 record as per database(coz my records are in desc.order). I mean its giving row index as per grid and not as per my actual table(primary key).
I am trying to update a row of the child gridview through a link button template field but how do I fetch the datakeys of the child gridview ?
View 1 RepliesI want to find a control in gridview using client id of the control as the id is changing dynamically. I am getting the client id but it is not getting assigned in a variable whether of string type or object type.
the code is as follows...................
Dim expdate As
String
expdate = e.Item.Cells(1).FindControl("txtExpenseDate1").ClientID
this is fetching client id but not assign it to expdate.............
ExpenseDate = Convert.ToString(CType(e.Item.FindControl("expdate"), TextBox).Text)
I have one page on which there are 6 labels and six text box for subject apart from this there are 2 to 3 other text box and label for studnt information. i want to do in such a way that if i enter student enroll no i get his/her name ,dept,sem,all subjects on 6 labels and marks related to subject in text box. In table there are fields
Marks_Entry
Student_Enroll Student_Name Sem Program subject Marks
1 sss 1 BCA Basic Communication Skills 75
1 sss 1 BCA Mathematical Foundation 85
[code]...
now when i am entering roll no in form then student name ,program, sem is fetched but in label 1 to label 6 same subject name that is 1st subject name is copied and in text box also first marks are fetched in all textboxes..my c# code on student enroll textbox is this
protected void txtEnroll_TextChanged1(object sender, EventArgs e) {
conn.Open();
qry = "SELECT * FROM Marks_Entry WHERE Student_Enroll_No = '" + txtEnroll.Text + "'";
SqlCommand cmd = new SqlCommand(qry, conn);
SqlDataReader dr = cmd.ExecuteReader();
[code]...
how can i get different values from database
I am developing an application in C# and Sql Server.
View 3 RepliesLang-ASP.net using C# and Sql server 2005
i m trying to use the sql datareader to fetch a single row at a time i wanna know can we use it to fetch a single row at a time or not if yes i m unable to figure out what i m doing wrong here bcus its not returning any data
[Code]....
of course data is present in my table bcuz when i m using dataset i m able to the return the single row throuugh dataset