|
Posted by Erland Sommarskog on 06/23/06 18:59
Lucky (tushar.n.patel@gmail.com) writes:
> yeah there is no table. its just a database list that i need.
So how does the actual cursor declaration look like? The code you
posted was incorrect, as it referred to a non-existing column. It's
very difficult to assist when I don't really know what you are trying
to do.
> and the business logic is very very big to paste here. i need some
> different tables in different DB and the idea of using the foreachloop
> is interesting but i dont know wether it will work with more than 250
> lines of PL SQL code.
PL/SQL? What are you using? MS SQL Server or Oracle?
To me it sounds very funny of wanting to run 250 lines of business logic
in multiple databases. I can envision situations where this may be
necessary, but I can also see this as a result of a poor design.
If you explained what your are actually trying to achieve in business
terms, it may be easier to suggest a good solution.
For a general discussion on multiple databases, this section in my
article on dynamic SQL may give some ideas:
http://www.sommarskog.se/dynamic_sql.html#Dyn_DB.
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Navigation:
[Reply to this message]
|