oracle10g

Parsing second word in string, in Oracle.

I need to write a bit of SQL which parses the second word of any given string, or if there is no space, the entire string. The logic is 'XXX YYYYY ZZZZZ' would return YYYY, 'XXX YYY' would return YYY and 'XXXXXX' would return XXXXXX. Any suggestions? Is there a way of using SUBSTR and the 2 positions within the string? Rather an u...

Revoking permission in oracle

In Oracle, if the current user tries to revoke all his permissions, what'll happen? For example, if I'm a user(John) created with WITH GRANT OPTION - can I revoke my permissions? ...

Reading Long Datatype and wirte it into an other Long Datatype

Hello I got a little Probelem: Im tring, with a SP, to read datas from Table SYSADM.aaTest and put it into MYSCHEMA.aaTest now my Problem is this Table has the Type Long in it. desc aaTest Name Null Typ ------------------------------ -------- ---------------- ID_TEST NOT NULL NUMBER...

ConcurrencyFailureException

Hi, How can I cause ConcurrencyFailureException in my Spring DAO when it accesses Mysql(myISAM) And Oracle(10g) ? I want to make a real database exception (not the mock one) from my Java code. Thanks ...

Oracle forms 10g, running a form

Hi guys, I have been facing trouble with running oracle 10g forms, I tried everything I know but it did not work. So please help me. My computer specifications: OS: windows xp service pack 2. Internet browser: Mozilla Firefox 3.6 RC 2. Database: Oracle 10g 10.2.0. Oracle developer suite 10g. JInitiator 1.3.1.30. jre-6u18-windows-i586....

Update single data row from table to another

How can I update a complete data row by using a data row from another table. Example: Table A ID | NAME | ... | ---------------------------- 1 | Test | ... | 2 | Test2 | ... | Table B ID | NAME | ... | ---------------------------- 1 | Test97 | ... | So I want to copy the con...

How to determine MAXSIZE of existing tablespace in Oracle

I need to determine the MAXSIZE that was set for a tablespace when it was created (Oracle 10g) I'm sure I'm missing something obvious, but the information isn't immediately apparent in the information in DBA_TABLESPACES ...

C# Getting the size of the data returned from and SQL query

How can I get the size in bytes of the data returned from the database when executing a query? The reason for this is to compare load on the database server using two different techniques. We were running reports built from the same dataset which would load the entire dataset for every report. Now we are caching the dataset and runnin...

Oracle date "Between" Query

I am using oracle database. i want to execute one query to check the data between two dates. NAME START_DATE ------------- ------------- Small Widget 15-JAN-10 04.25.32.000000 PM Product 1 17-JAN-10 04.31.32.000000 PM select * from <TABLENAME> where start_date BETWEEN '15-JAN-10' AND '17...

What options do I have to change WSDL location for a web service used within Apex?

Friends, Hope you can help with a problem I am encountering with Apex and Web Services. I have used the wizard within Apex to to create a web service reference. The webservice works as expected however... One of the wizard steps requires the location of the wsdl file, which for development is at location a. However when application...

Coalesce in Oracle

How to coalesce a table in oracle and What is it's syntax ? ...

How can I check the last time stats was run on Oracle without using OEM

I want to check the last time stats was run on my Oracle 10g server. I would normally do this via OEM, but for unrelated reasons OEM is down. Is there some way I can check this using just sqlplus? It would be extra helpful if the output was reasonably formatted. ...

Oracle sequence caching

I am trying to implement a sequence in an Oracle database to act as a surrogate key creator for a table. For performance reasons, I want this sequence to be cached. I have read that there are potential pitfalls when using cached sequences since rollbacks and instance failures will result in missed values. This got me to thinking. Let...

How is my id being generated with JPA using Hibernate with the Oracle 10g dialect?

I have some code: @Id @SequenceGenerator(name = "SOMETHING_SEQ") @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "SOMETHING_SEQ") @Column(name = "SOMETHING", nullable = false) private Long id; How is hibernate providing my id? I see in my database there a single sequence named 'hibernate_sequence' and no other hibern...

how to query (oracle) database table structure in C# / (ADO?).NET 2.0

I want to get table metadata for all table columns. Like type string(varchar2)/int/float/datetime and length for strings etc. Cheers! -Matti ...

is it possible to lock oracle 10g database table with ADO.NET?

I have a table that contains a maximum value that needs to be get and set by multiple programs. How can I lock the table for a while when old value is got and new is updated in C#? In other words: string sql = "lock table MaxValueTable in exclusive mode"; using (DbCommand cmd = cnctn.CreateCommand()) { cmd.CommandText = sql; ...

How to import a partitioned table into a table with a different number of partitions? (Oracle 10g)

I have an existing database with tables which each have 4 partitions (there are tables using both RANGE and HASH partitioning). I need to import it into another database with a pre-created schema where the same tables will have 8 partitions. How do I do this? Does this "just work" if I do a table-level import? ...

Validating Column Data Stored as CSV Against Another Table

I wanted to see what some suggested approaches would be to validate a field that is stored as a CSV against a table containing appropriate values. Althought it would be desired, it is NOT an option to split the CSV list into another related table. In the example data below I would be trying to capture the code 99 for widget A. Below i...

How can we set the profile option from a PL/SQL procedure?

How can we set the profile option from a PL/SQL procedure? ...

Oracle forms API - c-based compile error

i am trying to compile a c-based forms api program on Linux x86_64 using command gcc -m32 -I"$ORACLE_HOME/forms/api" -L"$ORACLE_HOME/forms/lib" -L"$ORACLE_HOME/lib" -ld2f fapi.c it fails with a bunch of undefined references. $ORACLE_HOME/lib/libd2f.so: undefined reference to `sifom' $ORACLE_HOME/lib/libd2f.so: undefined ref...