ORA-02243:invalid ALTER INDEX or ALTER MATERIALIZES VIEW option
Hi, Friend,
I am changing all the index to another tablespace of one of my schema.When I run the DDL script,got the error:
ORA-02243:invalid ALTER INDEX or ALTER MATERIALIZES VIEW option
I checked the metalink, got nothing.Anyone can help? Thanks!
I also googled some info,like:
Oracle Error :: ORA-02243
invalid ALTER INDEX or ALTER MATERIALIZED VIEW option
Cause
An option other than INITRANS, MAXTRANS,or STORAGE is specified in an ALTER INDEX statement or in the USING INDEX clause of an ALTER MATERIALIZED VIEW statement.
Action
Specify only legal options.
But I still can't find the clue.
Similar Messages
-
To Whom it may Concern,
I am attempting to add two columns Comm_id and Ben_id to a table in SQL Developer (Oracle).
Here is the syntax I am using:
ALTER TABLE ACCTMANAGER
ADD (Comm_id NUMBER(10)),
Ben_id VARCHAR(2);
The spool file I'm getting as a result of the script above:
Error starting at line 1 in command:
ALTER TABLE ACCTMANAGER
ADD (Comm_id NUMBER(10)),
Ben_id VARCHAR(2)
Error report:
SQL Error: ORA-01735: invalid ALTER TABLE option
01735. 00000 - "invalid ALTER TABLE option"
*Cause:
*Action:
DESC acctmanager
Thank you in advance.4b60e01f-2ea5-40fe-a161-fc12d38d09e5 wrote:
To Whom it may Concern,
I am attempting to add two columns Comm_id and Ben_id to a table in SQL Developer (Oracle).
Here is the syntax I am using:
ALTER TABLE ACCTMANAGER
ADD (Comm_id NUMBER(10)),
Ben_id VARCHAR(2);
The spool file I'm getting as a result of the script above:
Error starting at line 1 in command:
ALTER TABLE ACCTMANAGER
ADD (Comm_id NUMBER(10)),
Ben_id VARCHAR(2)
Error report:
SQL Error: ORA-01735: invalid ALTER TABLE option
01735. 00000 - "invalid ALTER TABLE option"
*Cause:
*Action:
DESC acctmanager
Thank you in advance.
try as below instead
ALTER TABLE ACCTMANAGER
ADD (Comm_id NUMBER(10), Ben_id VARCHAR(2)); -
Urgent Please help: ORA-00940: invalid ALTER command
I am not able to start my oracle db that is running Solaris 10, Oracle 10g.
I made the following changes to Oracle Parameter and now I am not able to start.
alter system set "_fix_control"='5705630:ON' scope=spfile;
I get this error: ORA-00940: invalid ALTER command
I am not even able to reset that parameter back, since oracle db won't start?
I get this error when i run "startsap: on command
Please help
Thanks
Kuamr
Message was edited by:
Kumar Subramaniam
Message was edited by:
Kumar SubramaniamI have renameed the spfile and try to start sap using initPR2.ora file and it worked fine and then I did this to re-create teh spfile.
sqlplus / assysdba
create spfile from pfile;
shutdown immediate;
startup;
Everything works fine.
Thanks for the quick response. -
Encountered ORA-01722 Invalid number when query doc from view
Hi all,
I have the following view.
Select item, to_number(wo) a
from tablea
union all
select item, wo
from tablebb
The problem rise ( ORA-01722) when I try to search for wo from the view after the view has been created. The wo field in tablea was varchar2 where user will key in the number only. And wo in tabebb is number, I can't change the column format as it is belong the my standard application table. How to solve this problem ?
Thanks
Limsm**** wrote:
I try to simplified my query. In fact, there are several where clause for both tables. The reason is because of the varchar2 field in WO at tablea versus the numeric field in WO for tableb. OK. The problem then is almost certainly that you have non-numeric characters in the column but you don't happen to have non-numeric characters in the columns that match all the other predicates.
Oracle is free to apply the TO_NUMBER function before it applies some or all of the predicates you specify in your WHERE clause. If it happens to apply the TO_NUMBER on a row that has non-numeric data before it applies the condition in the WHERE clause that filters out that particular row, you'll get an error. If, on the other hand, Oracle happens to filter out the row before applying the TO_NUMBER, you'll get the results you expect. It all comes down to which plan Oracle picks. But, in general, there is no guarantee about whether you'll get an error or whether you'll get the data you want.
You can define your own function
CREATE OR REPLACE FUNCTION my_to_number( p_str IN VARCHAR2 )
RETURN number
IS
l_num NUMBER;
BEGIN
l_num := to_number( p_str );
RETURN l_num;
EXCEPTION
WHEN others THEN
RETURN null;
END;and use that instead of to_number in your query. That will catch the exception if the function is applied to a row before one of the predicates is applied.
Justin -
Invalid column index error in sql developer
Hi,
I was trying to create stored procedures, functions and packages in sql developer which is connected to Oracle 11g. My instructor is able to execute all of them without any errors in 10g. However, when I try to execute them, I get- "Invalid column index error". Any suggestions on how to rectify this error?Hi,
That is probably an
ORA-17003: Invalid column index
Which is a JDBC error. Is Java/JDBC somehow involved?
If not, could you please post one of the failing statements?
Regards
Peter -
ORA-02248: invalid option for ALTER SESSION when logging in from client
Hi,
I am a junior dba and I was hoping if someone could help me out with a problem I am having. I recently installed on oracle 10g client on my windows machine. I am trying to remote connect to my database on a unix box but I am getting the below error when trying to connect from the client.
ERROR:
ORA-00604: error occurred at recursive SQL level 1
ORA-02248: invalid option for ALTER SESSION
I've done some digging around on this and I think it might be something to do with the NLS_LANG setting maybe. I'm not sure though and to be honest I'm a bit lost on this.
Any help would be greatly appreciated. Cheers.
Rgs,
RobPlease see below
BANNER
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for Linux: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production -
Error ORA-02248 invalid option for ALTER SESSION
Hi All,
I'm using windows vista.I have installed oracle database 11g.Now, SQL Developer is working fine in this.I gave the sid as orcl and gave my username and password in sqldeveloper and it works.
But the host string is not working in forms and sql plus.How do i know which host string i should give??I came to know that the tnsnames.ora which is present in the oracle home directory should be copied to forms directory also.I did that too but still forms,reprorts and sql plus are not working.I get two errors namely ORA-02248 invalid option for ALTER SESSION and TNS could not resolve service name .Pls suggest how to proceed.Thanks in advance....
Regards,
GowthamUnfortunately you forgot to mention forms/reports version. Currently only one Developer Suite version is certified on Vista running 11g,don't ignore software/hardware requirements.
It's 10.1.2.0.2 and that package requires additionally patch 6153263.
Werner -
ORA-03217: invalid option for alter of TEMPORARY TABLESPACE
Hi all
I have a database with 300 Users approximantely.
Suddenly I was reported about slowly connection and looked to my database. And I saw that Temporary tablespace with name MUVTEMP is 0% used and in it there is no .dbf file
Then I do ls on my data files directory and saw there MUVTEMP01.dbf!
But it's not using it. Then I want to add another .dbf file. It created this file physically but not joined it to my temporary tablespace.
Then I did it with Oracle EM, clicked on "Show SQL" and there was written
ALTER TABLESPACE "MUVTEMP"
ADD
DATAFILE '/home/oracle/OraHome1/oradata/linux/test.dbf' SIZE
5M
I run it from EM it gave this error
ORA-03217: invalid option for alter of TEMPORARY TABLESPACE
Then I run this SQL in sqlplus
ALTER TABLESPACE "MUVTEMP"
ADD
TEMPFILE '/home/oracle/OraHome1/oradata/linux/test.dbf' SIZE
5M
it created file physically, but I can't see this file as temporary tablespace's file. It's not using....
Where is my mistake???
Thanks...Hi,
try this query:
select s.sid || ',' || s.serial# sid, s.username, u.tablespace, substr(a.sql_text, 1, (instr(a.sql_text, ' ')-1)) sql_text,
round(((u.blocks*p.value)/1024/1024),2) size_mb
from v$sort_usage u, v$session s, v$sqlarea a, v$parameter p
where s.saddr = u.session_addr
and a.address (+) = s.sql_address
and a.hash_value (+) = s.sql_hash_value
and p.name = 'db_block_size'
group by s.sid || ',' || s.serial#, s.username, substr(a.sql_text, 1, (instr(a.sql_text, ' ')-1)), u.tablespace, round(((u.blocks*p.value)/1024/1024),2); -
"ORA-02248: invalid option for ALTER SESSION" -- Urgent request
Hi All,
We use Discoverer 3.1.36.06 and are in middle of a 3i to 10g upgrade for Discoverer for a data warehouse setup. Our databases where upgraded to 10g from 9i and now we get the error message saying:
"ORA-02248: invalid option for ALTER SESSION"
I got some very helpful info abt the prob from the link below.
Discoverer 3i Issue with 10.2.0.3 - ORA-02248
We are mid way through the 3i to 10g upgrade and just need a quick fix for the next 2-3 weeks while the upgrade is finished.
Does any one know if changing the NLS language and applying the post longon trigger on Database id's would help in resolving this connection issue temporarily.
Any advice is deeply appreciated.
Thanks.
Edited by: Paul S on Dec 15, 2008 3:01 PM Corrected the linkHi,
There are two types of trigger you can use: database triggers and discoverer triggers. You probably want to use a database trigger.
If you are using an APPS mode EUL (ie. logging using Applications username/passwords) then you will be logging in as the APPS database user and the syntax is:
create or replace trigger APPS.disco_logon_trigger after logon ON APPS.SCHEMA
begin dbms_session.set_nls('nls_date_format', '''DD-MON-YYYY'''); end;
If it is a database EUL and the database user is gl_inq then the syntax would be
create or replace trigger gl_inq.disco_logon_trigger after logon ON gl_inq.SCHEMA
begin dbms_session.set_nls('nls_date_format', '''DD-MON-YYYY'''); end;
Rod West -
ORA-02248: invalid option for ALTER SESSION
I deploy application in OC4J 10.1.3, it use Oracle 8.0.5.0.0, but when I try connect DB, it gives me error:
ORA-00604 Error occured at recursive SQL Level 1
ORA-02248 Invalid Option for Alter Session
Can someone please help me with this.From which version of Designer/SCM are you exporting and to which version are you importing? Please give the complete version number as shown in the Help->About dialog. For example, Oracle SCM 9i (9.0.2.10) and Oracle SCM 10g (9.0.4.6).
- Suresh -
Form6i connecting to DB11g, ORA-02248: invalid option for ALTER SESSION
when i am try to connect forms6 to database 11G then receiving this error:
ORA-02248: invalid option for ALTER SESSION ,
any one can help.
Regard
MKI believe Forms 6i issues this:
ALTER SESSION SET REMOTE_DEPENDENCIES_MODE = SIGNATURE
See if it is valid in Oracle 11.
If that is not the problem, run your form with trace on, and view the SQL statements passed. From my notes, trace is :
In C:\Orant\Net80\admin\SQLNET.ORA, set:
trace_level_client = 16
then run the form. File produced is named in:
trace_directory_client = C:\ORANT\NET80\TRACE
trace_file_client = C:\ORANT\NET80\TRACE\cli.trc
Please report back what you find. -
Deployment Error ORA-02248: invalid option for ALTER SESSION
While trying to deploy application on oc4j standalone 10.1.2, I receive the following error:
ORA-00604: error occurred at recursive SQL level 1
ORA-02248: invalid option for ALTER SESSION
Any ideas?Hello,
Which kind of application are you deploying?
What the application is doing with the database during deployment? (what j2ee components are you using that could access the DB during deployment)
Regards
Tugdual Grall -
Local Domain Index query fails with ora-01410: invalid rowid
Hello!
I have a task to implement partitioned domain index for range partitioned table.
As I understood from reference http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28425/dom_idx.htm
the main difference is to provide support for partitioning operations by
implementing corresponding ODCI interface functions.
For the first I decided to create something simple to not spend time on system partitioned
index storage table. My problem is that domain index works correctly when it's created without
support for partitioning and produces "*ORA-01410: INVALID ROWID*" when it's created
with LOCAL option.
Test query:
SELECT /* +index(from_sample_index) */ * FROM index_in_partitioned_tbl WHERE position_between(card_no) < 50 ORDER BY card_no DESC;
Index creared in this way returns 3 rows:
CREATE INDEX from_sample_index ON index_in_partitioned_tbl (card_no) INDEXTYPE IS position_indextype;
When index has been creared with LOCAL option I got "ORA-01410: INVALID ROWID" :
CREATE INDEX from_sample_index ON index_in_partitioned_tbl (card_no) INDEXTYPE IS position_indextype LOCAL;
I don't post implementation's source code to reduce amount of text in post. It works for global index.
If I copy rowid from index storage table and then put it into something like
SELECT card_no FROM index_in_partitioned_tbl WHERE rowid = 'AAAXHGAAEAAAFERAAh';
then it will be executed successfully without any errors.
I suppose the error could be somehow linked with "alter index" calls that Oracle makes when local domain index is created.
The calls are made with option "AlterIndexRebuild" - possibly they mark index as invalid (though it's shown as valid in SQL Developer)Solved :)
when index is LOCAL calls for ODCIINDEXSTART - ODCIINDEXFETCH - ODCIINDEXCLOSE are executed for each partition of base table.
In my case ODCIINDEXFETCH returns row_id's regardless of partition that are currently scanned for values. So first call returned rowid values for all partitions not only for the first partition and validation failed with "ora-01410: invalid rowid" -
ORA-01722: Invalid number - error only in Oracle 10g?
While trying to insert a numeric value into a decimal column, I get this error. Hitherto, my update statements used to look fine.
Can anyone let me know if this enforcement is specific to Oracla 10g? I am running :
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Thanks in advance for your help!
NiranjanWell, you've a blank space which isn't a number, that's why you have an error.
Please see the following example to have a default value :
SQL> create table tutu (id number, text varchar2(10));
Table created.
SQL> alter table tutu modify id default 0;
Table altered.
SQL> insert into tutu values (' ', 'NoWork');
insert into tutu values (' ', 'NoWork')
ERROR at line 1:
ORA-01722: invalid number
SQL> insert into tutu values (null,'NullValue');
1 row created.
SQL> insert into tutu (text) values ('Default');
1 row created.
SQL> insert into tutu values (1,'NonDefault');
1 row created.
SQL> select * from tutu;
ID TEXT
NullValue
0 Default
1 NonDefault
SQL> Nicolas.
Message was edited by:
N. Gasparotto -
I am getting "ORA-00900: invalid SQL statement" error.?
I did installed oracle 11gR2. and used "DBMS_METADATA_DIFF.COMPARE_ALTER('TABLE','TBL_A','TBL_A','USER1','USER2')" to see the result like below, but I am getting "ORA-00900: invalid SQL statement" error. Any idea?
I am using:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for 32-bit Windows: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
SQL> desc user1.tbl_a
Name Null? Type
FIELD_A1 NOT NULL NUMBER
FIELD_A2 VARCHAR2(20)
FIELD_A4 NOT NULL NUMBER(5,2)
FIELD_A5 VARCHAR2(10)
FIELD_A6 NOT NULL NUMBER(2)
SQL> desc user2.tbl_a
Name Null? Type
FIELD_A1 NOT NULL NUMBER
FIELD_A2 VARCHAR2(50)
FIELD_A3 DATE
FIELD_A4 NUMBER(5,2)
FIELD_A5 NOT NULL VARCHAR2(10)
SQL> select dbms_metadata_diff.compare_alter('TABLE','TBL_A','TBL_A','USER1','USER2') from dual
expected result:
DBMS_METADATA_DIFF.COMPARE_ALTER('TABLE','TBL_A','TBL_A','U1','U2')
ALTER TABLE "U1"."TBL_A" ADD ("FIELD_A3" DATE)
ALTER TABLE "U1"."TBL_A" DROP ("FIELD_A6")
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A2" VARCHAR2(50))
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A4" NUMBER(5,2) DEFAULT 0)
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A4" NULL)
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A5" NOT NULL ENABLE)Thanks for reply rp,
I got result using "select dbms_metadata_diff.compare_alter('TABLE','TBL_A','TBL_A','USER1','USER2') from dual"
Maybe you are looking for
-
New Ipod Touch will not connect or sync
I recently got a replacement Ipod Touch. I connected it to my computer and can see it in the My Computer window, however Itunes cannot connect or sync to it. It's not there. I have another Ipod Touch, it connects but will not Itunes does not recog
-
APPLE TV video set to incorrect value
I chose the HD setting on my apple TV and now I can not see anything. How do I get this back to normal? I know that I should not have selected this setting, but it happened. I hope someone can help. Steve
-
MSI H77MA-G43 AND INTEL 2ND GEN
Hello, i have made a budget pc for a friend with the following config: MSI H77MA-G43 INTEL I5 2400 MSI GTX 550 TI I have installed all the drivers but i can´t get any audio or ethernet. I've read about this and i come to a conclusion that might be so
-
IDVD reduces quality of original recording
My source video is DV from a hard-drive handycam. A 50-minute video uses 10.2 GB. The quality is terrific. When I use Sony's software in Windows to burn directly to a disc, the image quality viewed on a plasma screen TV is professional-looking. When
-
Strange behaviour of Time Machine.
I am getting the enclosed notice from Time Machine: Even so the backing is to 2 TB disk and the backup is about 250GB. The Hard Drive Was empty before the backup started. What is going wrong? Thanks, Amnon