473,320 Members | 1,535 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,320 software developers and data experts.

Problems getting the result fields to show up in a Table Adapter

Greetings,

I'm creating a website using ASP.NET. In creating my DAL I've got a
Table Adapter that I've set up to use an existing Stored Procedure from
an SQL Server 2000 database. However, when I select the stored
procedure I want to use the fields that are returned do not show up in
the listbox for that stored procedure. If I continue and attempt to
finish the Table Adapter I get the following error (even though the
Adapter is created)...

"Generated Select Statement.
Invalid object name #TempNoPatch."

Here is the entire stored procedure that I'm attempting to connect to.

<--- Begin code ---->

create procedure Monthly_Billing_Report

@StartDate varchar(10),
@EndDate varchar(10)

as

exec usp_Billing_Report_by_Main @StartDate, @EndDate

select MainAcctNum, MainAcctName, AutoAttnTime, OperatorTime, PatchTime,
NumCalls from MonthlyBillingReport

<--- End Code --->

Essentially, it fills a table in the database and then returns that
table. The #TempNoPatch is a temporary table used in the
usp_Billing_Report_by_Main procedure. Why is the Adapter getting hung
up on the temp table in the second procedure? I'm just returned an
actual table that is defined in the database. You would think it'd know
what the results would look like from that.

Thanks,

Andrew
Jul 28 '08 #1
2 1741
Andrew,

As you show it now it is nowhere an ASP.Net or VB.Net question.

You show only a part of your transaction SQL code.

Does that work in the Query analyzer.

As it there shows a resultset and you have provided the right parameters to
your DataAdapter, then I don't see why it would not show up, but give us at
least the code you use to set the parameters plus the dataadapter code, I
don't believe that anybody can give you real an advise in this based on
whatg you have showed now. (It can be but that can a child than as well with
a lucky guess).

Cor

"Andrew Cooper" <ka************@gmail.comschreef in bericht
news:%2****************@TK2MSFTNGP02.phx.gbl...
Greetings,

I'm creating a website using ASP.NET. In creating my DAL I've got a Table
Adapter that I've set up to use an existing Stored Procedure from an SQL
Server 2000 database. However, when I select the stored procedure I want
to use the fields that are returned do not show up in the listbox for that
stored procedure. If I continue and attempt to finish the Table Adapter I
get the following error (even though the Adapter is created)...

"Generated Select Statement.
Invalid object name #TempNoPatch."

Here is the entire stored procedure that I'm attempting to connect to.

<--- Begin code ---->

create procedure Monthly_Billing_Report

@StartDate varchar(10),
@EndDate varchar(10)

as

exec usp_Billing_Report_by_Main @StartDate, @EndDate

select MainAcctNum, MainAcctName, AutoAttnTime, OperatorTime, PatchTime,
NumCalls from MonthlyBillingReport

<--- End Code --->

Essentially, it fills a table in the database and then returns that table.
The #TempNoPatch is a temporary table used in the
usp_Billing_Report_by_Main procedure. Why is the Adapter getting hung up
on the temp table in the second procedure? I'm just returned an actual
table that is defined in the database. You would think it'd know what the
results would look like from that.

Thanks,

Andrew
Jul 29 '08 #2
Cor Ligthert[MVP] wrote:
Andrew,

As you show it now it is nowhere an ASP.Net or VB.Net question.

You show only a part of your transaction SQL code.

Does that work in the Query analyzer.

As it there shows a resultset and you have provided the right
parameters to your DataAdapter, then I don't see why it would not show
up, but give us at least the code you use to set the parameters plus
the dataadapter code, I don't believe that anybody can give you real
an advise in this based on whatg you have showed now. (It can be but
that can a child than as well with a lucky guess).

Cor

"Andrew Cooper" <ka************@gmail.comschreef in bericht
news:%2****************@TK2MSFTNGP02.phx.gbl...
>Greetings,

I'm creating a website using ASP.NET. In creating my DAL I've got a
Table Adapter that I've set up to use an existing Stored Procedure
from an SQL Server 2000 database. However, when I select the stored
procedure I want to use the fields that are returned do not show up
in the listbox for that stored procedure. If I continue and attempt
to finish the Table Adapter I get the following error (even though
the Adapter is created)...

"Generated Select Statement.
Invalid object name #TempNoPatch."

Here is the entire stored procedure that I'm attempting to connect to.

<--- Begin code ---->

create procedure Monthly_Billing_Report

@StartDate varchar(10),
@EndDate varchar(10)

as

exec usp_Billing_Report_by_Main @StartDate, @EndDate

select MainAcctNum, MainAcctName, AutoAttnTime, OperatorTime,
PatchTime, NumCalls from MonthlyBillingReport

<--- End Code --->

Essentially, it fills a table in the database and then returns that
table. The #TempNoPatch is a temporary table used in the
usp_Billing_Report_by_Main procedure. Why is the Adapter getting
hung up on the temp table in the second procedure? I'm just returned
an actual table that is defined in the database. You would think
it'd know what the results would look like from that.

Thanks,

Andrew
Thanks for the response but I got it worked out.

Andrew
Jul 29 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: | last post by:
Hello, Sorry to ask what is probably a simple answer, but I am having problems updating a table/database from a PHP/ PHTML file. I can Read From the Table, I can Insert into Table/Database, But...
3
by: Antoine Bloncourt | last post by:
Hello everybody Sorry to bother you but I have a problem writing datas into a file ... I want to make a backup of my MySQL database and put the result into a ..sql file. To do this, I use...
11
by: Siv | last post by:
Hi, I seem to be having a problem with a DataAdapter against an Access database. My app deletes 3 records runs a da.update(dt) where dt is a data.Datatable. I then proceed to update a list to...
0
by: hzgt9b | last post by:
Using VS2003, VB.NET, Here's some pseudo code that I'm trying to get to work... if <a specific record existsthen do nothing else <insert the specific record> Endif I've got the code...
12
by: Bruce One | last post by:
For all the ORM i have searched around, I have always found two big problems: 1) To update or delete a set of records you must first bring it to memory. If you are inside a loop and have to do it...
9
by: Frank | last post by:
Hi, imagine there's a WEB application reading data from an Oracle database to visualize in using DataGrids in the clients browser. Yes, sounds simple, just create OracleConnection + OracleCommand...
9
by: Martin Arvidsson | last post by:
Hi! I have two computed datafields that i am displaying in my windowsform. When i try to update the dataset and commit the transaction. I get an error message telling me that i cant update...
22
by: Sri | last post by:
All Recenetly our shop migrated to DB2 V8 from V7. We are in IBM System Level: z/OS 1.6.1 @ RSU 0702. Processor : IBM 2064-1C7 (z/900) # 1B89 Mode: 64-bit One of my application is facing...
2
by: rustyc | last post by:
Well, here's my first post in this forum (other than saying 'HI' over in the hi forum ;-) As I said over there: ... for a little side project at home, I'm writing a ham radio web site in...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.