Solved

inaccuracy between a DB table and its boud Asp.net Grid View

Posted on 2009-04-14
7
185 Views
Last Modified: 2012-05-06
Hello,
I have one Sql Server 2005, bound to an Asp.net web application.
There is something weird happening!!

There is one page using a grid view, and in it there is one column "Stock"  that is displaying wrong values for some records.
Those values are wrong because they are different from the DB table.
I would say like 20% of the records in this GV are having this problem.

And, there is one text box and a button on the page, where the user can enter a product code to filter the relative record in the GV.
When all the records are displayed in the GV with no filter value set, suppose that we check in the whole list the records ABC, and we found a stock 0 instead of 15, that's not good because in the DB table it's 15.
But if we filter the ABC we foung 15 !!
Can someone help please!
0
Comment
Question by:Nyana22
7 Comments
 
LVL 15

Accepted Solution

by:
spprivate earned 370 total points
ID: 24139784
I guess there is a problem in your select query.This causes the weird result coming up
0
 
LVL 14

Assisted Solution

by:GiftsonDJohn
GiftsonDJohn earned 80 total points
ID: 24139858
Please post the code.
0
 

Author Comment

by:Nyana22
ID: 24139871
i don't thing there is a problem in the select, because i tested it.

and now i created a new page, where the data source is the same stored procedure and it worked fine!
and by the way on my pc (development) there were no problem, only it happened on the server.!!
thanks
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 
LVL 75

Assisted Solution

by:Anthony Perkins
Anthony Perkins earned 50 total points
ID: 24140655
>>on my pc (development) there were no problem, only it happened on the server<<
Ah, yes.  That is a very common problem. It is called the "But it works on my workstation" syndrome.
0
 
LVL 15

Expert Comment

by:spprivate
ID: 24140722
Please post the code
0
 
LVL 15

Expert Comment

by:spprivate
ID: 24152465
Can you explain what was the issue
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 24153529
And more importantly why I was awarded points.
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

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

by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
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.

816 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now