oracle

Cannot disable index during PL/SQL procedure

I've written a PL/SQL procedure that would benefit if indexes were first disabled, then rebuilt upon completion. An existing thread suggests this approach: alter session set skip_unusable_indexes = true; alter index your_index unusable; [do import] alter index your_index rebuild; However, I get the following error on the first alt...

recovering dual table in Oracle

Someone has accidentally dropped dual table.Now we need dual table and whats the way to bring it back to the original state before dropping of the dual table? ...

Is there a nvl() function in Ruby or do I have to write it myself?

I want to use an equivalent of Oracle's nvl() function in Ruby. Is there a built in function or do I have to write one myself? Edit: I am using it to rewrite some sql to ruby: INSERT INTO my_table (id, val) VALUES (1, nvl(my_variable,'DEFAULT')); becomes plsql.my_table.insert {:id => 1, :val => ???my_variable???} ...

Oracle: How can I get all the triggers linked to a specific table?

Hi, I'm searching for a way to retrieve all the triggers where there is an action linked to a specific table. I don't want to read manually all the triggers I have on the server as there are too many. Any ideas? Thanks ...

Oracle JPublisher

Hi! I want to know why we need to use JPublisher? And maybe someone can give good tutorials using Oracle JPublisher for beginners? Best regards! ...

Is there a printf function in Oracle WebForms?

Is there a function to format a text in Oracle WebForms like printf in PHP? ...

How to distinguish date at midnight from date w/o time in Oracle?

I would like to distinguish date at midnight (i.e. '12/05/2010 00:00:00') from date without time specified (i.e. '12/05/2010'). This value is provided by user, sometimes it is only date which is important, sometimes it is date and time and later the application is expected to show the time only when it was explicitly provided. So for the...

dbms_xmlschema fail to validate with complexType

Preface: This works on one Oracle 11gR1 (Solaris 64) database and not on a second and we can't figure out the difference between the two databases. Somehow the complexType causes the validation to fail with this error: ORA-31154: invalid XML document ORA-19202: Error occurred in XML processing LSX-00200: element "shiporder" not empty O...

How to copy a 110GB table with BLOBs from one schema to another on ORACLE

Hello, I have a table containing 110GB in BLOBs in one schema and I want to copy it to another schema to a different table. I only want to copy a column of the source table so I am using an UPDATE statement, but it takes 2,5 hours to copy 3 GB of data. Is there a faster way to do this? Thank you update: The code I am using is very...

Query on Triggers..

Created One Trigger in Oracle.. SQL> CREATE OR REPLACE TRIGGER student_after_insert 2 AFTER INSERT 3 ON student 4 FOR EACH ROW 5 BEGIN 6 @hello.pl 9 END student_after_insert; 10 / Contents of hello.pl are:- BEGIN DBMS_OUTPUT.PUT_LINE('hello world'); END; And.. the result is pretty good, as the content of h...

Convert array of 0 and 1 to base36 string

Hello, everybody. Here is the thing. I have an array of 0 and 1. It is supposed to be a binary string. What i need is to format it to string that contains base36 conversion from that binary. In other words, i need to do this: array of 1 and 0 -> some kind of binary number -> convert to base36 number -> put it into string. How to do that?...

Cannot drop Oracle queue table with DBMS_AQADM.DROP_QUEUE_TABLE

I'm trying to clean up an accidental installation of LOG4PLSQL into the wrong (i.e., SYS) schema. There is a queue table called QTAB_LOG that needs to go away. I have successfully stopped and dropped the associated queue: call DBMS_AQADM.STOP_QUEUE('LOG_QUEUE'); call DBMS_AQADM.DROP_QUEUE('LOG_QUEUE'); But dropping the queue table its...

SQL ORACLE - Datatable in where clause

Currently I have a sql call returning a dataset from a MSSQL database and I want to take a column from that data and return ID's based off that column from the ORACLE database. I can do this one at a time but that requires multiple calls, I am wondering if this can be done with one call. String sql=String.Format(@"Select DIST_NO FRO...

Creating an object relational schema from a Class diagram

Hi Ladies and Gents. I'd like some help converting the following UML diagram: UML Diagram The diagram shows 4 classes and is related to a Loyalty card scheme for an imaginary supermarket. I'd like to create an object relational data base schema from it for use with Oracle 10g/11g. Not sure where to begin, if somebody could give me a ...

Maximum capabilities of MySQL

How do I know when a project is just to big for MySQL and I should use something with a better reputation for scalability? Is there a max database size for MySQL before degradation of performance occurs? What factors contribute to MySQL not being a viable option compared to a commercial DBMS like Oracle or SQL Server? ...

Using maven to generate an ear file for ADF...?

I am noticing that Oracle ADF has its own EAR structure. There is an adf folder created like so, inside the EAR, along with the WAR file and standard META-INF directory is this 'adf' directory: adf /com /companypackagehere bc4j.xcfg /META-INF adf-config.xml connections.xml Must I recreate this using file moves.....

Oracle syntax - should we have to choose between the old and the new?

Hi, I work on a code base in the region of about 1'000'000 lines of source, in a team of around eight developers. Our code is basically an application using an Oracle database, but the code has evolved over time (we have plenty of source code from the mid nineties in there!). A dispute has arisen amongst the team over the syntax that w...

Oracle SQL: Multiple Subqueries Unioned Without Running Original Query Multiple Times.

So I've got a very large database, and need to work on a subset ~1% of the data to dump into an excel spreadsheet to make a graph. Ideally, I could select out the subset of data and then run multiple select queries on that, which are then UNION'ed together. Is this even possible? I can't seem to find anyone else trying to do this and ...

Got a minus one from a read call.

I connect to a database with read only access using SQL developer. It's a TNS connection. I use a tnsnames.ora, forwarding port script and SQL Developer. In the past, occasionally, when connecting, I get a error message Got a minus one from a read call. Vendor Code 0 If I do a reboot, it goes away. Another friend suggested changed the ...

Oracle equaivalent of java System.currentTimeMillis()?

Hi, I want to be able to store the current time in milliseconds in an Oracle number field. How do I do this via a query? select systimestamp from dual; returns the actual timestamp. Is there anyway that I can convert this into milliseconds the same way Java's System.currentTimeMillis() does? ...