I have a script which reads from XML and tries to execute the SL present in it on the database.
But I am getting the error ORA-38910 when I execute the select commands on the database.
The odd thing is the script sometimes works and sometimes does not. Also it works with smaller batches than with the entire population.
So I was hoping to learn what causes the Oracle error : ORA-38910: BATCH ERROR mode is not supported for this operation. The Oracle documentation I read on this errors, were unfortunately not very helpful for me.
Related
I am writing a wrapper shell or perl script which does open an oracle session using sqlplus and then execute some sql files by scanning a directory. So as part of this , lets say if we have multiple sql files in a directory,
for eg: first.sql,second.sql,third.sql
I am planning to create a single file(AllSqlFilesInDirectory.sql) with below content.
>cat AllSqlFilesInDirectory.sql
#first.sql
#second.sql
#third.sql
>
Now I am planning to run the file AllSqlFilesInDirectory.sql by opening an oracle sqlplus session.
After executing, I am planning to come out of the oracle sqlplus session and I am planning to search for any errors in the log file.
If there are any errors, I would like to execute rollback. But I think as I am out of that sqlplus session, rollback is not possible. I am just concerned about the DML statements that were executed as part of those multiple sql files in the directory.
So I have these doubts
Can I simply ignore and not be concerned about rollback at all
Can I do the rollback for a session which was already closed?
If above is valid, then how can do it?
Can I simply ignore and not be concerned about rollback at all
That's a business question you'd have to answer. If you want the changes to be rolled back if there is an error, you'd need to do a rollback.
Can I do the rollback for a session which was already closed?
As a practical matter, probably not. Technically, you can using flashback transaction backout but that is generally way more complexity that you'd normally want to deal with.
If above is valid, then how can do it?
Rather than writing to a log file and parsing the log file to determine if there were any errors, it is most likely vastly easier to simply put a
whenever sqlerror exit rollback
at the top of your script. That tells SQL*Plus to rollback the transaction and exit whenever an error is encountered. You don't have to write logic to parse the log file.
Whenever sqlerror documentation
I'm working on migrating some reports from Oracle Discoverer to OBIEE. I've already exported the layouts from discoverer to OBIEE. I have all I need in the OBIEE Admin tool now, but when I try to perform this operation:
I got this message:
I've read in many forums that this is because of the query (enter link description here) but I've executed the query in SQL Developer and all is fine.
Any idea?
Thanks,
I can see from the icon on your object that it is an Opaque View that your trying to run View Data on.
This is probably because of a syntax issue in your opaque view. Make sure the code in the opaque view doesn't end with a semi-colon or slash, that will cause problems. Try eliminating any blank lines, if there are any. However, without knowing exactly the syntax of the code it's impossible to say exactly what the cause is.
It's also possible that there is a connection script attached to the connection pool you are using to View Data, running on connection or before execution with bad syntax.
Otherwise have a look in the Admin Tool log to see if there's more information about what is causing the error. It will usually contain more detailed information than is passed back through the GUI.
I need some help in auditing in Oracle. We have a database with many tables and we want to be able to audit every change made to any table in any field. However, I find it difficult to locate the descriptions for ERROR code. For example,
So my question is which table or view holds these messages all together.
oerr - Oracle error messages, is a utility (script not an executable) which comes with unix and linux based oracle installations and can be found in the bin directory. Input to this script could be the error code.
this utility extracts error messages with suggested actions from the standard Oracle message files
Just because it uses awk functionalities, it is not supported in windows.
Usage details : http://www.oracledistilled.com/oracle-database/troubleshooting/using-the-oerr-utility-to-aid-in-error-investigation/l
SQLERRM and SQLCODE functions extract error messages and error codes, but it returns value only inside the exception handler and not in any SQLs, outside them, it always return success message!
So, I doubt if there is a possible solution for what you ask.
I am running a long query(having lot of subqueries) with rownum from VB6 which is giving ORA-03113 end of file on communication after approximately 1 minute. The query run fine from Toad. When the same query is run from VB6 without ROWNUM then query works fine. Also this is parameterised query, if i remove parameters and enter the values directly in query, then also query run fines from vb6.
This query was running fine few days back. Now it is not.
I tried increasing the connection timeout but still i am getting error after 1 minute. Could anyone suggest what could be the problem?
This often indicates that an ORA-00600 internal error has been thrown on the server. Check the alert log and trace files.
ORA-03113 on the client side is one of the oracle catch-all error that is thrown. You need to see if there is any additional error that accompany that error to give you an idea of the problem. The problem can be server side if there is an ORA-00600 that accompanies the ORA-03113 with the same sid/serial of the session. Check the server logs for both the ORA-03113 and any addition error. If there are no server side error, then the error is client side. Check for any network/connection related issue, but since the query works without the rownum network is probably not the cause. That means its probably a client side bug, now comes the need to enable client side tracing of the connection and see if you can generate a consistent issue and trace that you can then use to raise a case with oracle support to see if there is a bug you can get patch/fixed on the client.
Two related applications use a function in a package in several queries to return some data as CSV. The column being selected and concatenated is a CLOB field and can contain HTML, special characters, etc. The applications have few users and so are not heavily used. One is a Flex application that consumes Oracle HTTP services, and the other is an ASP.NET application that uses ODP.NET. The applications are really one integrated application with hyperlinks to each other.
Yesterday, I received several notifications of a strange error:
ORA-01031: insufficient privileges ORA-06512
The line number in the package in the error details indicates that the error was caused by the function being used in the select clause. It would occur when called by either application about 75% of the time.
Am I correct that an ORA-06512 occurred in the function that then caused an ORA-01031 insufficient privilege error? Unfortunately, ORA-06512 is a very generic error and doesn't tell me anything. And why would it cause an invalid privilege error? The Oracle user accounts being used by both applications have the execute privilege on the package that contains the function.
Regarding the function... it has been used for about 2 years in production without any issue. Also, when I imported the data to QA yesterday and tested it, no error would occur, no matter how many times I hammered the server with requests. But in production, the error would occur about 75% of the time with exactly the same parameters.
The DBA tried to help me with a trace, but we could not find the error message in the trace files.
Today, everything is back to normal in production. Even if I hammer the server with requests the error will stubbornly refuse to occur.
What caused this very strange behaviour yesterday? Do any of the gurus here have any ideas?
EDIT: I just realized one important detail. The column in the table that is being selected and concatenated into CSV by the function is a CLOB.
If the client applications were running "SELECT clob_to_csv(clob_col) FROM ..." and it returned an invalid privilege SOMETIMES, then it is probably something the function is trying to do, rather than the select statement not having sufficient privilege to execute the function.
Not quite clear on what it might do that may require a privilege. Does it use a file (UTL_FILE) or network connection / web service ?
Could be some sort of odd data (a very large clob perhaps).