Quantcast
Channel: MySQL Forums - Connector/NET and C#, Mono, .Net
Viewing all articles
Browse latest Browse all 1451

"Parameter not found in the collection" when using TableAdapter (no replies)

$
0
0
I have a .NET 2.0 strongly typed dataset with a TableAdapter that pulls data from a MySql 5.5.8 table using .NET Connector 6.3.6. I'm trying to add a new query to the adapter using an existing stored procedure. When I try to add the query the wizard in VS2010 throws the error "Parameter 'in_schedule_id' not found in the collection". How can I get this to work? Here's the stored procedure I'd like the table adapter to use:

DELIMITER $$ 
DROP PROCEDURE IF EXISTS `myDB`.`get_schedule_by_id` $$ 
CREATE PROCEDURE `myDB`.`get_schedule_by_id` (
    IN in_schedule_id INT
) COMMENT 'Get all schedules for a given team' 
BEGIN 
    SELECT s.id,
           s.team_id AS "team",
           s.versus_team_id AS "versus_team",
           DATE_FORMAT(s.start_time, '%W %b. %e, %Y') AS "date",
           DATE_FORMAT(s.start_time, '%l:%i %p') AS "start_time",  
           DATE_FORMAT(s.end_time, '%l:%i %p') AS "end_time", 
           s.type_id AS "schedule_type", 
	  s.venue_id AS "venue",  
	  CASE IFNULL(s.shared, 0) WHEN 0 THEN 'false' ELSE 'true' END S "shared",  
           s.split, 
	  IFNULL(s.notes, '') AS "notes"
	FROM myDB.schedules s
	INNER JOIN `myDB`.schedule_types st ON st.id = s.type_id
	INNER JOIN `myDB`.venues v ON v.id = s.venue_id
	INNER JOIN `myDB`.teams t ON t.id = s.team_id
	INNER JOIN `myDB`.divisions d ON d.id = t.division_id
	WHERE s.id = in_schedule_id; END $$

I should add that this stored procedure works fine in my existing application, I'm just running into problems refactoring it to a data access layer.

Viewing all articles
Browse latest Browse all 1451

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>