Re: [cx-oracle-users] callproc dbms_metadata.add_file
Brought to you by:
atuining
From: Werner M. <wer...@gm...> - 2014-09-28 16:28:06
|
Hi, I was mistaken that the conversion error was caused by the filesize parameter, it is caused by the value for filetype. Taking the constant (3 for logfile) works. Still wondering how to write the oracle constant so that it works - I definitely missed the DBMS_DATAPUMP here but it does not work anyway. Anything else I need works fine (exporting only a view tables and selecting the rows with a subquery) - nice! thanks, Werner Gesendet: Mittwoch, 24. September 2014 um 21:18 Uhr Von: "Werner Moser" <wer...@gm...> An: cx-...@li... Betreff: [cx-oracle-users] callproc dbms_metadata.add_file Hi, I'm writing a little script which exports some data from my database and I want to use dbms_datapump. It almost works, I am stuck with the logfile though. To create one, you have to use the function dbms_datapump.add_file: DBMS_DATAPUMP.ADD_FILE ( handle IN NUMBER, filename IN VARCHAR2, directory IN VARCHAR2, filesize IN VARCHAR2 DEFAULT NULL, filetype IN NUMBER DEFAULT DBMS_DATAPUMP.KU$_FILE_TYPE_DUMP_FILE), reusefile IN NUMBER DEFAULT NULL; when I call it with the first five parameters, I always get an ORA-6502 - for the size of the file (which is not needed for the logfile ...) cur.callproc('dbms_datapump.add_file',[handle,'test.log','EXP_IMP',102400,'KU$_FILE_TYPE_LOG_FILE']) cx_Oracle.DatabaseError: ORA-06502: PL/SQL: numeric or value error: character to number conversion error As far as I have found out only positional parameters can be used, i.e. a dict or key/value is not supported - if it was I could use only the needed parameters here (handle, filename, directory and filetype). so, how can I get this to work? the parameter filesize is optional but how can I write that? br, Werner ------------------------------------------------------------------------------ Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk_______________________________________________ cx-oracle-users mailing list cx-...@li... https://lists.sourceforge.net/lists/listinfo/cx-oracle-users[https://lists.sourceforge.net/lists/listinfo/cx-oracle-users] |