Wrox Home  
Search P2P Archive for: Go

  Return to Index  

enterprise_java_beans thread: How to return ResultSet type value from EJB to Servlet?


Message #1 by Edward <zhangsc@n...> on Sat, 01 Jun 2002 18:35:23 +0800
This is a multi-part message in MIME format.

------=_NextPart_000_000C_01C214AB.1A8D5BB0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 8bit

You can´t have a collection of the dataSource.


   Julio Oliveira
Buenos Aires - Argentina
Java Developer - Instructor - Cursos @-Mail
-------------------------------------------
JOliveiraAR@y...
Oliveira_julio@y...

***********************************************************************

  -----Mensaje original-----
  De: pradeep kumar.s [mailto:pradeepkumar_s@h...]
  Enviado el: sábado 15 de junio de 2002 3:04
  Para: Enterprise Java Beans
  Asunto: [enterprise_java_beans] Re: How to return ResultSet type valu e
from EJB toServlet?


  Hi Craig,

  One of essential featues inclusive of using EJB's is also to have the
advantage of utilising various services like conn poolin,
security,transaction mgmt etc for concurrency,scalability etc  which are
written by experts for various vendors

  what does thou say

  Pradeep







  >From: Amit Bhatia
  >Reply-To: "Enterprise Java Beans"
  >To: "Enterprise Java Beans"
  >Subject: [enterprise_java_beans] Re: How to return ResultSet type valu e
from EJB to Servlet?
  >Date: Mon, 10 Jun 2002 06:14:17 -0400
  >
  >Yes Craig
  >I agree with you completely!
  >If we want to use Resultset then might as well make direct JDBC calls.
Why
  >use EJB???
  >and if we are using EJB then use Beans why use ResultSet?
  >
  >
  >
  >
  > > -----Original Message-----
  > > From: craigb@w... [SMTP:craigb@w...]
  > > Sent: Monday, June 10, 2002 4:53 PM
  > > To: Enterprise Java Beans
  > > Subject: [enterprise_java_beans] Re: How to return ResultSet type
  > > value from EJB to Servlet?
  > >
  > > You just need to create a simply class that implements Serializable
and
  > > within it create a member variable for storing the ResultSet, e.g.
  > >
  > > import java.sql.ResultSet;
  > > import java.io.Serializable;
  > >
  > > public class ReturnResultSet implements Serializable

  > >
  > > private ResultSet rs;
  > >
  > > public ResultSet getResultSet() { return rs;
  > > }
  > > public void setResultSet(ResultSet newRS)

  > > set rs = newRS;
  > > }
  > > }
  > > However, I would question your architecture of wanting to pass a
resultset
  > > from an EJB to a servlet. Why are you using an EJB? Why do you need
the
  > > entire resultset?
  > >
  > > Cheers
  > >
  > > Craig
  >
  >


----------------------------------------------------------------------------
--
  Chat with friends online, try MSN Messenger: Click Here
  --- Change your mail options at http://p2p.wrox.com/manager.asp or to
unsubscribe send a blank email to



  Return to Index