Home: Perl Programming Help: Intermediate:
Sybase bulk copy from MDA tables

New User

Oct 1, 2013, 9:01 PM

Views: 3389
Sybase bulk copy from MDA tables

I need to extract all the SQL's from MDA tables in Sybase using Perl and analyze the SQL's. These are SQL's written by various program's on the application tables and will be captured in Mon (monProcessSQLText) tables if MDA Is on. The way Mon tables work is it has a buffer size, let us say 10,000 records. When 10K records are captured, it gets recycled. So, when a program reads the Mon table, it gets the latest set of records, if read with the same database connection. I need to have a program which does a bulk copy of data from monProcessSQLText in one database to a temp file in another database. No database link available. I need to be reading continuously with a defined interval and should happen on the same connection. Some of the Perl BCP library does not table the connection as parameter which means whenever BCP library is called, it establishes connection internally. What is the best solution for this.


Veteran / Moderator

Oct 3, 2013, 3:23 PM

Views: 3369
Re: [webonly] Sybase bulk copy from MDA tables

In Reply To
I need to extract all the SQL's from MDA tables in Sybase

Sorry, I don't understand this. What do you mean by "extracting all SQL's"? SQL is a query language, not a database dictionary or metadata. OK, I have never used Sybase, maybe you are referring to a special Sybase feature, but I would be surprised it that were the case.