the query COmmandText was built by the Visual Studio IDE :
"SELECT Recd_ID, Game_ID, StartDate, EndDate, Status, Seats, SeatsTaken,
UserOrder, CurUser, NextUser, NextExpires, DraftSeconds, BankSeconds,
PositionOrder, DraftDelay, RealPlay, GameType, Price, Fee, Sport, Scoring
FROM Rooms"
then I append " WHERE (Recd_ID = 234)" (or whatever recd# I'm looking for)
the query works perfectly 99% of the time, and as you said either returns
the full row or an empty datatable, but then I get an occasional error
stating that the column "Sport" doesn't exist. in a 'Catch' I listed the
datacolumns for the table, only one column (Recd_ID) was there, the value was
the correct record#. the next attempt (refresh the page for instance) works
perfectly, and the failure doesn't occur again for hours or days, then it's
identical.
Thanks for your prompt reply too !!!
[quoted text, click to view] "Andrea Montanari" wrote:
> hi,
> Customh2 wrote:
> > I have a query, generated by Visual Studio.net in an ASP.net web-app
> > which normally works fine, but occasionally only returns one column
> > of the selected row.
> > the first column (Recd_ID) is the identity/key column, and when the
> > query fails, only this column is returned, another attempt a moment
> > later works fine. could this be an optomistic/pessimistic issue? is
> > there a workaround? I don't want to hold up the web request by
> > waiting some period of time then retrying. Any intuitive suggestions?
>
> it actually seems "nonsense" :|
> your code, which you do no show, should return "all or nothing" and not only
> part of a result...
> --
> Andrea Montanari (Microsoft MVP - SQL Server)
>
http://www.asql.biz http://italy.mvps.org > DbaMgr2k ver 0.19.0 - DbaMgr ver 0.63.0 and further SQL Tools
> --------- remove DMO to reply
>
>
hi,
[quoted text, click to view] Customh2 wrote:
> the query COmmandText was built by the Visual Studio IDE :
> "SELECT Recd_ID, Game_ID, StartDate, EndDate, Status, Seats,
> SeatsTaken, UserOrder, CurUser, NextUser, NextExpires, DraftSeconds,
> BankSeconds, PositionOrder, DraftDelay, RealPlay, GameType, Price,
> Fee, Sport, Scoring FROM Rooms"
>
> then I append " WHERE (Recd_ID = 234)" (or whatever recd# I'm looking
> for)
>
> the query works perfectly 99% of the time, and as you said either
> returns the full row or an empty datatable, but then I get an
> occasional error stating that the column "Sport" doesn't exist. in a
> 'Catch' I listed the datacolumns for the table, only one column
> (Recd_ID) was there, the value was the correct record#. the next
> attempt (refresh the page for instance) works perfectly, and the
> failure doesn't occur again for hours or days, then it's identical.
again, this really is an "abnormal" behavior.. never heard about something
like that... the whole select_list should always be retrieved, even in case
of empty sets...
can you reproduce the problem? I do think you should open a case with
Microsoft...
--
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz http://italy.mvps.org DbaMgr2k ver 0.19.0 - DbaMgr ver 0.63.0 and further SQL Tools
--------- remove DMO to reply