To get this stuff you
need to create a Ref Cursor to return recordset.
create or
replace PACKAGE Types AS
TYPE cursor_type IS REF CURSOR;
Now create a stored procedure to return multiple rows .
create or
replace
PROCEDURE
getAllCity(p_recordset OUT types.cursor_type) AS
BEGIN
OPEN
p_recordset FOR
select * from tbl_country;
Now put this code in your event.
string strconn = myDynconnStr;
OracleConnection conn = new OracleConnection(strconn);
OracleCommand objCmd = new OracleCommand();
objCmd.Connection = conn;
objCmd.CommandText = "getAllCity";
objCmd.CommandType = CommandType.StoredProcedure;
objCmd.Parameters.Add("p_recordset",
OracleType.Cursor).Direction = ParameterDirection.Output;
OracleDataAdapter odr = new OracleDataAdapter(objCmd);
DataSet ds
= new DataSet();
odr.Fill(ds);
GridView1.DataSource = ds.Tables[0];
GridView1.DataBind();
Hope it helps.
-Manas
=======================================
If this post is useful to you, please mark it as answer.