By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,468 Members | 1,859 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,468 IT Pros & Developers. It's quick & easy.

design for a simple file writer in j2ee environment

P: n/a
I need to do the following:
1) access the database with a simple query
2) post the results of that query to a file on a unix machine for nightly
ftp to a mainframe

I'm thinking of having either a new or existing data access object (DAO) do
the query and make a result set. What I'm debating, since its not a client
function, is whether to accumulate the results to data transfer objects
(DTOs), and then maybe pass them to a BDO to actually create the file? Or
should I just have one class do everything? Or something else.

I'm much better at writing code than designing, so I'd welcome your
opinions.

Thanks,
Eric
Jul 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Eric wrote:
I need to do the following:
1) access the database with a simple query
2) post the results of that query to a file on a unix machine for nightly
ftp to a mainframe

I'm thinking of having either a new or existing data access object (DAO) do
the query and make a result set. What I'm debating, since its not a client
function, is whether to accumulate the results to data transfer objects
(DTOs), and then maybe pass them to a BDO to actually create the file? Or
should I just have one class do everything? Or something else.

I'm much better at writing code than designing, so I'd welcome your
opinions.


Eric,

Ultimately it comes down to how flexible and re-usable you need the code
to be. All that stuff seems like overkill for what you are trying to do
-- unless this will be part of a larger app with re-usable modules.

BTW, most databases have some sort of utility for dumping data. E.g.,
SQL Server can output a result set as XML natively and Oracle has a XSU
utility to do it.

Ray

Jul 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.