C# .NET - SPS And crystal reports

Asked By Mamatha
10-Feb-12 12:21 AM
Hi All,
 
How to create a stored procedure and pass parameter to the crystal reports through stored procedures in asp.net c#
  Somesh Yadav replied to Mamatha
10-Feb-12 12:34 AM

To call Stored Procedure from crystal report,

Set data source of report to Stored Procedure (DataBase Expert Wizard). That procedure must met thses requirement

1- You must create a package that defines the REF CURSOR (type of field that will be retrieved).

2- The procedure must have a parameter that is a REF CURSOR type. This is because CR uses this parameter to access and define the result set that the stored procedure returns.

3- The REF CURSOR parameter must be defined as IN OUT (read/write mode).

4- Parameters can only be input (IN) parameters. CR is not designed to work with OUT parameters.

5- The REF CURSOR variable must be opened and assigned its query within the procedure.

6- The stored procedure can only return one record set. The structure of this record set must not change, based on parameters.

7- The stored procedure cannot call another stored procedure.

Create New Account
help
EnterpriseLibrary. Return Recordset from oracle stored procedure .NET Framework Hi, I'm trying to use an EnterpriseLibrary 3.1 and return recordset from oracle database using stored procedure. As you may know, oracle stored procedures have out parameter of type cursor in order to return a dataset. It seems like I need to add a paramenter of type cursor to execute this stored procedure, but I can't find the type for the cursor. Does enterprise Library support
difference between stored procedure and function also tell me which cursor type can use in stored procedure 1. Functions can be direclty used withing SQL statements (insert, delete, update, select) where as stored procedures cannot. 2. procedures can have output parameters and functions cannot have any output parameters
Cursor Data Type as Output Parameters SQL Server Dear Sir, It is possible to passed cursor data type as output parameters from SQL Stored Procedure. But Can you inform me how I can retrieve that using ADO in Visual 1) Becauseyou (1) MICROBRAIN (1) Recordset (1) Multiples (1) Sorry but you cannot retrieve this type of parameter from ADO. A passed cursor data type can only be used when the SP is called by another SP; not by an
Cursor I need difference between Explicit and implicit and Ref cursor. . . . . . . . . . . . . . . . . . . . . . . . .In oracle. . . . . . . HI A REF CURSOR have a return type and it as 2 type Strongly Typed Cursor and Weakly Typed Cursor but Cursor doesn't have return type Ex: TYPE ref_type_name IS REF CURSOR RETURN return_type; return_type represents
cursor functions hi all, i want to know about cursor functions in sql server.and also what is the use of this?. Defines the attributes of a Transact-SQL server cursor, such as its scrolling behavior and the query used to build the result set on which the cursor operates. DECLARE CURSOR accepts both a syntax based on the ISO standard and a syntax using a set of Transact-SQL extensions. ISO Syntax DECLARE cursor_name [ INSENSITIVE ] [ SCROLL ] CURSOR FOR select_statement [ FOR { READ ONLY | UPDATE [ OF column_name [ , . . .n ] ] } ] [;] Transact-SQL Extended Syntax DECLARE cursor_name CURSOR [ LOCAL | GLOBAL ] [ FORWARD_ONLY | SCROLL ] [ STATIC | KEYSET | DYNAMIC | FAST_FORWARD ] [ READ_ONLY | SCROLL_LOCKS | OPTIMISTIC ] [ TYPE_WARNING ] FOR select_statement [ FOR UPDATE [ OF column_name [ , . . .n ] ] ] [;] AURGUMENTS: cursor_name Is the name of the Transact-SQL server cursor defined. cursor_name must conform to the rules for identifiers. For more information about rules for