Heterogeneous Services ODBC to MS SQLSvr - ORA-00904 error
Hello, I have successfully setup a heterogeneous Services ODBC to MS SQLSvr using the steps outlined at http://www.orafusion.com/art_orahs.htm.
My problem is, the only queries that run without errors are SELECT * FROM tablename@xxx. When I try SELECT colname FROM tablename@xxx I get an ORA-00904: "colname": invalid identifier. Any thoughts?
Also, will I be able to update MS SQLSvr tables using this link?
Thanks.
Hello, Your suggestion worked. Even though all the column_names are lower case, if I surrounded the column names with double quotes the query would work.
Another question. I'm wanting to update a SQLServer table with data from a Oracle table using a query like:
INSERT INTO sql_table@xxx
SELECT * FROM oracle_table ;
Is this possible? I'm getting a "ORA-02025: all tables in the SQL statement must be at the remote database" error message which looks like I can't.
Thanks.
Similar Messages
-
I have a stored procedure that executes a query through a dblink to another database. The remote database is Oracle 8.1.7, the local database is Oracle 10.2.0. After making a minor change to the stored procedure, the procedure will not compile, issuing an ORA-00904 error for columns on the remote table being queried. Running the query outside the stored procedure works just fine. Compiling the procedure from our test server (also running Oracle 10.2.0) works fine. Attempts to return to previous code (without the minor change) also gets the same ORA-00904 error.
Anyone have any ideas regarding the cause of this error?I'm going to answer my own question:
Apparently, links to databases older than 9i can sometimes (perhaps at random) have the local cache in the shared pool get corrupted. The Oracle notes I saw do not describe exactly how the cache gets corrupted. This appears to be a longstanding bug without a solution - only a work around.
The work around is to flush the cache:
alter system flush shared pool;
The most relevant Metalink document I found was
Note:397658.1
https://metalink.oracle.com/metalink/plsql/f?p=130:14:1002445788225491569::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,397658.1,1,1,1,helvetica -
.Using Oracle Heterogeneous Services Connectivity to SQL Server :ORA-02068
Hi,
I using oracle HS to connect sql server but error ora-02068: following server from HSSQL and ORA-03135 connection lost contact.
step by step
1. Create the init.ora file = initHSSQL.ora
HS_FDS_CONNECT_INFO = HSSQL
HS_FDS_TRACE_LEVEL = OFF
2. modified listener.ora file
SID_LIST_LISTENERHSSQL =
(SID_LIST =
(SID_DESC=
(SID_NAME=HSSQL)
(ORACLE_HOME = C:\oraclexe\app\oracle\product\10.2.0\server)
(PROGRAM=hsodbc)
LISTENERHSSQL =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
(ADDRESS = (PROTOCOL = TCP)(HOST = CEPITA1403.siam.local)(PORT = 1521))
and start listernerHSSQL = pass
3.modified tnsname.ora :
HSSQL =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = CEPITA1403.siam.local)(PORT = 1521))
(CONNECT_DATA =
(SID = HSSQL)
(HS = OK)
and test by tnsping HSSQL = OK
4.setup ODBC SQL Server
Start --> Control Panel --> Administrative Tools --> Data Sources (ODBC)
Click on the ‘System DSN’ tab.
Click ‘Add’.
Name HSSQL
Click ‘Test Data Source…’.--> Pass
5
create public database link HSSQL
connect to sa
identified by xxxxxxxx
using 'HSSQL';
Database Link created.
6. select * from ACCOUNT_CODE@HSSQL;
show error message : ora-02068: following server from HSSQL and ORA-03135 connection lost contact.
Please let me know.
rose
Edited by: user7218901 on Mar 25, 2009 12:39 AMDo you have all of your parameter files set up correctly?
You need to have a hsora file in the hs/admin directory for ioi for instance, initioiDB.ora. In this file you need to set up your hs init parameters. This is an example of what's in one of mine:
HS_FDS_CONNECT_INFO = Mapics
HS_DB_NAME = MAPICS
HS_DB_DOMAIN = WORLD
HS_FDS_TRACE_LEVEL = ON
The you need to have an entry in the tnsnames.ora file in the network/admin directory for hsodbcxtrad. The sid should be set to ioiDB.
You can find documentation on how to manage heterogenous services in the online documentation.
Managing Heterogenous Services Using Generic Connectivity
Hope this helps
Eric
I have been trying to set up a database link between Oracle and SQL Server, currently both on the same Windows NT machine.
I managed to create the link as follows:
CREATE PUBLIC DATABASE LINK ioi
CONNECT TO IOItest IDENTIFIED BY mba
USING 'hsodbcxtrad';
The link is created successfully.
I then try to run a query and get the following error :
select * from dealer@ioi
ERROR at line 1:
ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
[Generic Connectivity Using ODBC]DRV_InitTdp: [Microsoft][ODBC SQL Server
Driver][SQL Server]Login failed for user '\'. (SQL State: 28000; SQL Code:
18456)
ORA-02063: preceding 2 lines from IOI
I have added a UID and PWD to the registry settings for the SQL Server DSN but this makes no difference. Do I need to specify a username and password somewhere else ?
Thanks
Hugh -
EA1 - Export result of query to clipboard gives ORA-00904 error
I ran the following SQL in a SQL Developer worksheet:
create table EXTCHAR_TEST (TEST_COL VARCHAR2(2000));
insert into EXTCHAR_TEST(TEST_COL) values ('(ASCII) ABCDEFGHIJKLMNOPQRSTUVWXYZ');
insert into EXTCHAR_TEST(TEST_COL) values ('(UTF-8) ŁłŃńŅņŇňʼnŊŋŌōŎŏŐőŒœŔŕŖŗŘřŚ');
insert into EXTCHAR_TEST(TEST_COL) values ('(UTF-8) ŗňŅŒŅ ňŁœ ōř ňʼnŇň łřŔŅ ŇŏŎŅ?');
select TEST_COL, DUMP(TEST_COL,1016) from EXTCHAR_TEST;
I then tried to right-click on the results and export them as CSV to the clipboard. Whenever I try this (possibly other ways too, I haven't tried) I get this error:
An error was encountered performing the requested operation:
ORA-00904: "DUMP(TEST_COL,1016)": invalid identifier
00904. 00000 - "%s: invalid identifier"
* Cause:
* Action:
Vendor code 904Error at Line: 2 Column: 16
Edited by: gclough on Sep 28, 2009 4:03 PMHi Barry,
I think I'm using the latest "EA1" version, which I downloaded from here:
[http://www.oracle.com/technology/software/products/sql/index21_EA1.html]
I have just confirmed using the sample script, that the problem still exists. I was connected to a v9.2.0.5.0 database... if that makes any difference.
* Run SQL
* Right-Click on results
* Export Data -> csv...
* Clipboard
* Click "Apply"
* Error... :-(
Greg.
About
Oracle SQL Developer 2.1.0.62
Version 2.1.0.62
Build MAIN-62.61
Copyright © 2005,2009 Oracle. All Rights Reserved.
IDE Version: 11.1.1.2.36.54.96
Product ID: oracle.sqldeveloper
Product Version: 11.1.1.62.61
Version
Component Version
========= =======
Java(TM) Platform 1.6.0_11
Oracle IDE 2.1.0.62.61
Versioning Support 2.1.0.62.61
Properties
Name Value
==== =====
apple.laf.useScreenMenuBar true
awt.toolkit sun.awt.windows.WToolkit
class.load.environment oracle.ide.boot.IdeClassLoadEnvironment
class.load.log.level CONFIG
class.transfer delegate
com.apple.macos.smallTabs true
com.apple.mrj.application.apple.menu.about.name "SQL_Developer"
com.apple.mrj.application.growbox.intrudes false
file.encoding Cp1252
file.encoding.pkg sun.io
file.separator \
http.agent Mozilla/5.0 (Java 1.6.0_11; Windows XP 5.1 x86; en_US) ICEbrowser/v6_1_3
ice.browser.forcegc false
ice.pilots.html4.ignoreNonGenericFonts true
ice.pilots.html4.tileOptThreshold 0
ide.AssertTracingDisabled true
ide.bootstrap.start 9450010258892
ide.build MAIN-62.61
ide.conf C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\sqldeveloper\bin\sqldeveloper.conf
ide.config_pathname C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\sqldeveloper\bin\sqldeveloper.conf
ide.debugbuild false
ide.devbuild false
ide.extension.search.path sqldeveloper/extensions:jdev/extensions:ide/extensions
ide.firstrun true
ide.java.minversion 1.6.0_04
ide.launcherProcessId 5404
ide.main.class oracle.ide.boot.IdeLauncher
ide.patches.dir ide/lib/patches
ide.pref.dir C:\Documents and Settings\Greg\Application Data\SQL Developer
ide.pref.dir.base C:\Documents and Settings\Greg\Application Data
ide.product oracle.sqldeveloper
ide.shell.enableFileTypeAssociation C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\sqldeveloper.exe
ide.splash.screen splash.gif
ide.startingArg0 C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\sqldeveloper.exe
ide.startingcwd C:\Documents and Settings\Greg
ide.user.dir C:\Documents and Settings\Greg\Application Data\SQL Developer
ide.user.dir.var IDE_USER_DIR
ide.work.dir C:\Documents and Settings\Greg\My Documents\SQL Developer
ide.work.dir.base C:\Documents and Settings\Greg\My Documents
java.awt.graphicsenv sun.awt.Win32GraphicsEnvironment
java.awt.printerjob sun.awt.windows.WPrinterJob
java.class.path ..\..\ide\lib\ide-boot.jar
java.class.version 50.0
java.endorsed.dirs C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\endorsed
java.ext.dirs C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\ext;C:\WINDOWS\Sun\Java\lib\ext
java.home C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre
java.io.tmpdir C:\DOCUME~1\Greg\LOCALS~1\Temp\
java.library.path C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;c:\Program Files\Microsoft IntelliType Pro\;C:\progra~1\Oracle\product\11.1.0\db_1\bin;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Progra~1\Oracle\product\11.1.0\client_2\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Common Files\Microsoft Shared\Windows Live
java.naming.factory.initial oracle.javatools.jndi.LocalInitialContextFactory
java.runtime.name Java(TM) SE Runtime Environment
java.runtime.version 1.6.0_11-b03
java.specification.name Java Platform API Specification
java.specification.vendor Sun Microsystems Inc.
java.specification.version 1.6
java.util.logging.config.file logging.conf
java.vendor Sun Microsystems Inc.
java.vendor.url http://java.sun.com/
java.vendor.url.bug http://java.sun.com/cgi-bin/bugreport.cgi
java.version 1.6.0_11
java.vm.info mixed mode
java.vm.name Java HotSpot(TM) Client VM
java.vm.specification.name Java Virtual Machine Specification
java.vm.specification.vendor Sun Microsystems Inc.
java.vm.specification.version 1.0
java.vm.vendor Sun Microsystems Inc.
java.vm.version 11.0-b16
jdbc.driver.home /C:/progra~1/Oracle/product/11.1.0/db_1/
jdbc.library /C:/progra~1/Oracle/product/11.1.0/db_1/jdbc/lib/ojdbc6.jar
line.separator \r\n
oracle.home C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper
oracle.ide.util.AddinPolicyUtils.OVERRIDE_FLAG true
oracle.jdbc.Trace true
oracle.translated.locales de,es,fr,it,ja,ko,pt_BR,zh_CN,zh_TW
oracle.xdkjava.compatibility.version 9.0.4
orai18n.library /C:/progra~1/Oracle/product/11.1.0/db_1/jlib/orai18n.jar
os.arch x86
os.name Windows XP
os.version 5.1
path.separator ;
reserved_filenames con,aux,prn,lpt1,lpt2,lpt3,lpt4,lpt5,lpt6,lpt7,lpt8,lpt9,com1,com2,com3,com4,com5,com6,com7,com8,com9,conin$,conout,conout$
sqldev.debug false
sun.arch.data.model 32
sun.boot.class.path C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\resources.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\rt.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\sunrsasign.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\jsse.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\jce.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\lib\charsets.jar;C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\classes
sun.boot.library.path C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\jdk\jre\bin
sun.cpu.endian little
sun.cpu.isalist pentium_pro+mmx pentium_pro pentium+mmx pentium i486 i386 i86
sun.desktop windows
sun.io.unicode.encoding UnicodeLittle
sun.java2d.ddoffscreen false
sun.jnu.encoding Cp1252
sun.management.compiler HotSpot Client Compiler
sun.os.patch.level Service Pack 3
svnkit.sax.useDefault true
user.country US
user.dir C:\Program Files\Oracle\product\11.1.0\db_1\sqldeveloper\sqldeveloper\bin
user.home C:\Documents and Settings\Greg
user.language en
user.name Greg
user.timezone America/Los_Angeles
user.variant
windows.shell.font.languages
Extensions
Name Identifier Version Status
==== ========== ======= ======
Check For Updates oracle.ide.webupdate 11.1.1.2.36.54.96 Loaded
Code Editor oracle.ide.ceditor 11.1.1.2.36.54.96 Loaded
Database Connection Support oracle.jdeveloper.db.connection 11.1.1.2.36.54.96 Loaded
Database Object Explorers oracle.ide.db.explorer 11.1.1.2.36.54.96 Loaded
Database UI oracle.ide.db 11.1.1.2.36.54.96 Loaded
Diff/Merge oracle.ide.diffmerge 11.1.1.2.36.54.96 Loaded
Extended IDE Platform oracle.javacore 11.1.1.2.36.54.96 Loaded
External Tools oracle.ide.externaltools 11.1.1.2.36.54.96 Loaded
File Support oracle.ide.files 11.1.1.2.36.54.96 Loaded
File System Navigator oracle.sqldeveloper.filenavigator 11.1.1.62.61 Loaded
Help System oracle.ide.help 11.1.1.2.36.54.96 Loaded
History Support oracle.jdeveloper.history 11.1.1.2.36.54.96 Loaded
Import/Export Support oracle.ide.importexport 11.1.1.2.36.54.96 Loaded
Index Migrator support oracle.ideimpl.indexing-migrator 11.1.1.2.36.54.96 Loaded
JDeveloper Runner oracle.jdeveloper.runner 11.1.1.2.36.54.96 Loaded
Log Window oracle.ide.log 11.1.1.2.36.54.96 Loaded
Navigator oracle.ide.navigator 11.1.1.2.36.54.96 Loaded
Object Gallery oracle.ide.gallery 11.1.1.2.36.54.96 Loaded
Object Viewer oracle.sqldeveloper.oviewer 11.1.1.62.61 Loaded
Oracle Data Modeler Reports oracle.sqldeveloper.datamodeler_reports 11.1.1.62.61 Loaded
Oracle Database Browser oracle.sqldeveloper.thirdparty.browsers 11.1.1.62.61 Loaded
Oracle IDE oracle.ide 11.1.1.2.36.54.96 Loaded
Oracle SQL Developer oracle.sqldeveloper 11.1.1.62.61 Loaded
Oracle SQL Developer Data Modeler Viewer oracle.datamodeler 2.0.0.574 Loaded
Oracle SQL Developer Extras oracle.sqldeveloper.extras 1.1.1.62.61 Loaded
Oracle SQL Developer Migrations oracle.sqldeveloper.migration 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Antlr3 Translation Core oracle.sqldeveloper.migration.translation.core_antlr3 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - DB2 oracle.sqldeveloper.migration.db2 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Microsoft Access oracle.sqldeveloper.migration.msaccess 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - MySQL oracle.sqldeveloper.migration.mysql 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - SQLServer oracle.sqldeveloper.migration.sqlserver 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Sybase oracle.sqldeveloper.migration.sybase 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Teradata oracle.sqldeveloper.migration.teradata 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Translation Core oracle.sqldeveloper.migration.translation.core 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Translation Db2 oracle.sqldeveloper.migration.translation.db2 11.1.1.62.61 Loaded
Oracle SQL Developer Migrations - Translation UI oracle.sqldeveloper.migration.translation.gui 11.1.1.62.61 Loaded
Oracle SQL Developer Reports oracle.sqldeveloper.report 11.1.1.62.61 Loaded
Oracle SQL Developer SearchBar oracle.sqldeveloper.searchbar 11.1.1.62.61 Loaded
Oracle SQL Developer TimesTen oracle.sqldeveloper.timesten 2.0.0.62.61 Loaded
Oracle SQL Developer Unit Test oracle.sqldeveloper.unit_test 11.1.1.62.61 Loaded
Oracle SQL Developer Worksheet oracle.sqldeveloper.worksheet 11.1.1.62.61 Loaded
Oracle XML Schema Support oracle.sqldeveloper.xmlschema 11.1.1.62.61 Loaded
PROBE Debugger oracle.jdeveloper.db.debug.probe 11.1.1.2.36.54.96 Loaded
Peek oracle.ide.peek 11.1.1.2.36.54.96 Loaded
Persistent Storage oracle.ide.persistence 11.1.1.2.36.54.96 Loaded
QuickDiff oracle.ide.quickdiff 11.1.1.2.36.54.96 Loaded
Replace With oracle.ide.replace 11.1.1.2.36.54.96 Loaded
Runner oracle.ide.runner 11.1.1.2.36.54.96 Loaded
Snippet Window oracle.sqldeveloper.snippet 11.1.1.62.61 Loaded
Sql Monitoring Project oracle.sqldeveloper.sqlmonitor 11.1.1.62.61 Loaded
Tuning oracle.sqldeveloper.tuning 11.1.1.62.61 Loaded
VHV oracle.ide.vhv 11.1.1.2.36.54.96 Loaded
Versioning Support oracle.jdeveloper.vcs 11.1.1.2.36.54.96 Loaded
Versioning Support for Subversion oracle.jdeveloper.subversion 11.1.1.2.36.54.96 Loaded
Virtual File System oracle.ide.vfs 11.1.1.2.36.54.96 Loaded
Web Browser and Proxy oracle.ide.webbrowser 11.1.1.2.36.54.96 Loaded
audit oracle.ide.audit 11.1.1.2.36.54.96 Loaded
oracle.ide.indexing oracle.ide.indexing 11.1.1.2.36.54.96 Loaded
Edited by: gclough on Sep 30, 2009 4:39 PM -
ORA-00904 Error while running CMP EJB
When I am running my CMP bean, I get following error,
2006-07-02 09:58:17,171 DEBUG org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.AccountBean#fi ndByAccountNumber] Executing SQL: SELECT t0_a.ACCOUNT.UOID FROM ACCOUNT t0_a WHERE (t0_a.ACCOUNT.ACCOUNT_NUMBER = ?)
2006-07-02 09:58:17,250 ERROR [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.AccountBean#fi ndByAccountNumber] Find failed java.sql.SQLException:
ORA- 00904: "T0_A"."ACCOUNT"."ACCOUNT_NUMBER": invalid identifier.
Why is it giving invalide identifier? the length of this identifer is also less then 30 and there are no special characters being used in it.I think I have read that you cannot use the "." to navigate through the object, you can only use it for accessing a field of an object (i.e. a column of a table in the DB).
So, never use more than 1 "." in your requests. In your case, I guess that you need to reformulate the request. -
Oracle query on dblinked SQL Server tables returns ORA-00904 error
Hi,
I have created a dblink to a SQL Server database from Oracle using Generic Connectivity.
The following query returns ORA-00904 Invalid Identifier error in the WHERE clause (tblEmp.Empno)
SELECT "EmpNo","EmpName", "DeptName"
FROM tblEmp@sqlserver,
tblDept@sqlserver
WHERE tblDept.DeptNo = tblEmp.Empno
I had to enclose the column names in double quotes due to case sensitivitiy of the columns, but I can't do the
same for the WHERE clause.
1) So, how do I fix this error ?
2) Also how do I include Deptno column with table alias in the columns list?
(Deptno is ambiguous in Emp and Dept tables)
Regards,
SamAlex
Because using the aliases all the time can become annoying and lead to disparate standards when used by multiple developers. For a one-off query I would go with aliases in the query but if the linked tables are going to be interrogated extensively I would prefer to create vanilla views of the underlying tables so that the aliases aren't necessary.
Just my opinion, it feels a bit cleaner to do it this way - you only do the work once in creating the view and then you don't need to worry about the case sensitivity of the linked database. You can also refer to the source in the name of the view so you don't have to think about different source databases with the same table names.
Cheers
Ben -
ORA-00904 error in DBMS_STATS.GATHER_SCHEMA_STATS
Oracle 9.2.0.5 on Solaris
I am trying to run weekly stat gathering on a schema, using DBMS_STAT
I am getting this error on a specific table, wehich aborts the entire process:
ORA-00904: "SEARCHKEYWORKS": invalid identifier
there is no such field. the table creator confirmed that initally he called a field SEARCHKEYWORKS, but later dropped it and created a new one with different name. maybe we did run DBMS_STATS on this table before the change.
when trying to delete stats for this table, using bms_stats.delete_table_stats(ownname=> 'yyyy', tabname=> 'xxxx') I get a ORA-20000, unable to set values for column BRIEFDESCRIPTION, an existing column
this table is referenced from many other tables, so a simple drop/recreate would be a pain. any way to fix this?
Note: I can run the old-style command ANALYZE TABLE xxx COMPUTE STATISTICS just fine; its just the DBMS_STATS package that can't be run on this table.thanks for the support.
the weekly task that first reported the error was
EXECUTE DBMS_STATS.GATHER_SCHEMA_STATS('SSSSSS',DBMS_STATS.AUTO_SAMPLE_SIZE,FALSE,'FOR ALL COLUMNS SIZE 1',NULL,'DEFAULT',TRUE);
the log file showed the error. where looking which table was last analyzed I gathered it was this table.
then I tried manually only this table, from manager console using their default, which is:
dbms_stats.gather_table_stats(ownname=> 'SSSSSS', tabname=> 'XXXXXX', partname=> NULL);
Hey,
could you post your dbms_stats complete syntax?
Jaffar -
Hi ,
I am facing a problem in export utility 8i database, this is occuring after i installed the packaes required for java stored procedure, any suggestion is appreciated
L:\>exp userid=ubs/ubs owner=scott file=test.dmp log=test.log
Export: Release 8.1.7.0.0 - Production on Tue Jul 9 13:37:31 2002
(c) Copyright 2000 Oracle Corporation. All rights reserved.
Connected to: Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
With the Partitioning option
JServer Release 8.1.7.0.0 - Production
Export done in WE8ISO8859P1 character set and UTF8 NCHAR character set
server uses UTF8 character set (possible charset conversion)
About to export specified users ...
. exporting pre-schema procedural objects and actions
. exporting foreign function library names for user SCOTT
. exporting object type definitions for user SCOTT
About to export SCOTT's objects ...
. exporting database links
. exporting sequence numbers
. exporting cluster definitions
. about to export SCOTT's tables via Conventional Path ...
. . exporting table TEMP 0 rows exported
. exporting synonyms
EXP-00008: ORACLE error 904 encountered
ORA-00904: invalid column name
EXP-00000: Export terminated unsuccessfully
thankyou in advance for a reply
Regards
balaIt might be that you have not ran the exp script to build the correct views.
Some applications build tables with double quotes around them to force the table or view names to lower case. exp doesn't play well with that. You may have to go through and rename all the objects that were creates case specific. -
How to catch PL/SQL: ORA-00904 error?
Hi ,
I am trying to run the following PL/SQL Block and have trapped error code -904( for invalid column name) in the exception section block.
The column name in the select query does not exist in the emp table and as per my understanding since I have an exceptiion handler for this error it should be handled in Exception Block.
DECLARE
invalid_column exception;
pragma exception_init (invalid_column,-00904);
no number;
BEGIN
select empn into no from emp
where ename='king';
EXCEPTION
when invalid_column then
dbms_output.put_line(Column ane does not exist)
end;
1) Can You please let me know why this is not getting caught in Exception handler
*2) What changes should I make in Exception handler section so that Invalid column name is handled in the program*
Thanks and regards
HarmeetCheck this:
SQL> ed
Wrote file afiedt.buf
1 DECLARE
2 invalid_column EXCEPTION;
3 PRAGMA EXCEPTION_INIT(invalid_column,-00904);
4 v_col_check NUMBER := 0;
5 v_col_name VARCHAR2(10) := 'OWNE';
6 BEGIN
7 select COUNT(*) INTO v_col_check
8 from all_tab_cols
9 where table_name = 'ALL_OBJECTS'
10 AND column_name = v_col_name;
11 IF (v_col_check = 0) THEN
12 RAISE invalid_column;
13 END IF;
14 EXCEPTION
15 WHEN invalid_column THEN
16 DBMS_OUTPUT.PUT_LINE('Column '||v_col_name ||' does not exist in table all_objects');
17* END;
SQL> /
Column OWNE does not exist in table all_objects
PL/SQL procedure successfully completed.
SQL> This way you can check if the column is valid or not in case you are dynamically getting the column names -
ORA-00904 error while export table with CLOB
All,
I'm trying to export from Oracle Client 8.0.4 an specific Oracle 9i R2 schema, but this error appears. This error is related with tables that have CLOB field types, because schemas with tables without this field type can be exported with no error. I've already run the catexp.sql script, but it haven't solved this problem.
Does anyone can help me?
Thanks,
DaviYou can try performing the import of the dump to see if it would work with 8i client or the 8.0.4 client.
if not, you may not be able to use this method to move data into 8.0.4 database that is no longer spported by current tools.
you may then want to try use other techniques like dumping tables into flat files and then using SQL*Loader to load into 8.0.4.
http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:88212348059#14506966201668 -
Hi,
select statmnnt is giving output but while inserting is failing
getting B: MGR_NUM invalid identifier
NSERT INTO assc ( b.assc_nm,
b.STATUS_DT,
b.STATUS_ID,
b.first_nm,
b.last_nm,
b.curr_title_nm,
b.curr_field_sales_ind,
b.MGR_NM)
select c.assc_nm,
c.status_dt,
decode(c.STATUS,'ACTV',1,'INAC',2),
c.first_nm,
c.last_nm,
c.curr_title_nm,
'N',
c.MGR_NM
from ASSCGENTABLE_NEW c
where c.flag='I';should be...
INSERT INTO assc (
assc_nm,
STATUS_DT,
STATUS_ID,
first_nm,
last_nm,
curr_title_nm,
curr_field_sales_ind,
MGR_NM)
select c.assc_nm,
c.status_dt,
decode(c.STATUS,'ACTV',1,'INAC',2),
c.first_nm,
c.last_nm,
c.curr_title_nm,
'N',
c.MGR_NM
from ASSCGENTABLE_NEW c
where c.flag='I'; -
Having issues with a left join, getting ORA-00904 error
Ok this is something very similar to what I am facing, but dumbed down. None of these columns or tables names exist in real life (Very paranoid company I work for, understandable though) but the fundamental problem I am having is like below.
Basically I know I could have done something similar to this is MS SQL (Or am I dreaming?). If I am right or wrong I need to know a way around this.
Obviously if you comment out the "CAL.WEEK_SINCE_2005" and "AND CUST.week_since_2005 = CAL.WEEK_SINCE_2005" it would work. But I really need it to display the date as well. So it can be group'ed by week since 2005.
I will be joining other statements to this. I am hoping on doing this in one select statement instead of creating multiple tables as I am now. All the other joined tables will follow a VERY similar layout to this. So something like this is need to obtain the look.
When ran I get the following error.
I look forward to learning what I did wrong and how I can fix it. :)
select ORG.ORGANIZATION_NAME,
CUST.CUST_COUNT,
CAL.WEEK_SINCE_2005
FROM organization ORG,
calendar CAL
LEFT JOIN (
SELECT CAP.CURRENT_STORE,
CALEN.week_since_2005,
count(CAP.inactive_date) CUST_COUNT
FROM CUST_AGREE_PAST CAP,
calendar CALEN
WHERE CAP.active_date is not null
and CAP.inactive_code in ('T')
and CAP.inactive_date between '01-sep-07' and sysdate
and CAP.INACTIVE_DATE = CALEN.CALENDAR_DATE
and CAP.RSN_CODE_ID in (select rsn_code_id from reasons where title in ('FAIL', 'NO CALL'))
GROUP BY CAP.CURRENT_STORE,
CALEN.week_since_2005) CUST
ON PO.CURRENT_STORE = ORG.ORGANIZATION_NAME
AND CUST.week_since_2005 = CAL.WEEK_SINCE_2005Just noticed a problem (there might be others):
FROM organization ORG,
calendar CAL
LEFT JOIN (You cannot do that - you are mixing Oracle and ANSI join syntax. You have to do one or the other:
FROM organization ORG
JOIN calendar CAL on (ORG.col = CAL.col)
LEFT JOIN (....) -
Connecting Oracle(64bit) to SQL Server(32bit) with heterogeneous serv ODBC
Hi,
We are planing the migration of 32bit Oracle 9.2.0.8 (MS Windows Server 2003 EE SP1) to 64 bit Oracle 10.2.0.4 (MS Windows Server 2003 Standard x64 Edition SP2).
We have tested the migration using export/import procedure, and everything passed ok.
The problem is because the database we are planning to migrate (32bit) using Oracles heterogeneous Services ODBC agent in connection to 32 bit SQL Server 2000. When we have tried to implement that on 64bit 10.2.0.4 oracle we always get the message:
ORA-28545: error diagnosed by Net8 when connecting to an agent
Unable to retrieve text of NETWORK/NCR message 65535
Then we looked up the metalink and find the document: Is Generic Connectivity Available On Linux Or Windows 64-bit Platforms ? [*ID 361676.1*]
Is there any way to make the connection between 64bit Oracle 10.2.0.4 and 32bit SQL Server using system DSN within the Windows ODBC Data Sources with choosing the SQL Server driver?
The option with Database Gateway for ODBC (DG4ODBC) isn't free.
ThanksHi everyone
As far as I am aware, you need to install the Discoverer EUL into an Oracle database and then use an ODBC connection to SQL Server. This is because Discoverer has hooks into the Oracle database and is looking for features that only exist in an Oracle database. If you are using an Infrastructure, which is mandatory when using 4i, you can use that database to store your EUL using an ODBC connection over to SQL Server.
I hope this helps
Best wishes
Michael Armstrong-Smith
URL: http://learndiscoverer.com
Blog: http://learndiscoverer.blogspot.com -
Problem with Oracle Heterogeneous Services
Hi All,
I am trying to access SQL Server database using Oracle Heterogeneous Services and I am getting the following error in my tarce file:
Heterogeneous Agent Release
10.2.0.3.0
HS Agent received unexpected RPC disconnect
Network error 1003: NCR-01003: NCRS: Read error.
I have checed the tnsnames.ora / listener.ora and they are seems OK
tnsping is also working fine on HS
Thses are the steps that I followed :
1. setup system DNS
2. configure Oracle HS Initialization File under $ORACLE_HOME/hs/admin
3. configure tnsnames.ora under $TNS_ADMIN
4. configure listener.ora under $TNS_ADMIN
5. craete db link
6. querying db link gave the following error
"No more data to read from socket"
7. trace file under $ORACLE_HOME/hs/log shows the following error
Heterogeneous Agent Release
10.2.0.3.0
HS Agent received unexpected RPC disconnect
Network error 1003: NCR-01003: NCRS: Read error.
Please advice
Regards
OmerHi,
Thanks for the reply.
its not a new project. We have this running for quite a while now.
i have set the trace level from ON to DEBUG and the log file has the following info :
Oracle Corporation --- MONDAY JUL 27 2009 13:09:03.719
Version 10.2.0.3.0
hoagprd (2): ; hoagprd Entered.
HOACONN.C (244): ; [Generic Connectivity Using ODBC] version: 4.6.3.0.0070
HOACONN.C (295): ; Class version: 211
hoagprd (2): ; hoagprd Exited with retcode = 0.
hoaexit (6): ; hoaexit Entered.
hoaexit (6): ; hoaexit Exited with retcode = 0.
(0): ; Closing log file at MON JUL 27 13:09:11 2009.
# HS init parameters
HS_FDS_CONNECT_INFO = xxxxxx
HS_FDS_TRACE_LEVEL = DEBUG
HS_FDS_SHAREABLE_NAME = /usr/local/iodbc/lib/libiodbc.so
HS_FDS_TRACE_FILE_NAME = xxxxxx.trc
HS_FDS_TRACE_LEVEL=4
# ODBC specific environment variables
set ODBCINI=/usr/local/iodbc/odbc.ini
Regards -
1.5.4 ora-00904 when opening a package from the connections navigator
Hi
I downloaded 1.5.4 for windows and immediately checked to see if this long standing bug has been fixed
1.5.0.53 New file types not opened as plsql (and now neither a
However it hasn't so next thing I do is go the connections navigator to open a package which is the workaround for the above bug (any update on when that is going to be fixed would be appreciated).
If I double click to open a package I get an error message
ORA-00904: "ATTRIBUTE": invalid identifier
A single click on a package does not give any error. Double clicking on the same package in 1.5.1 does not give any error message
Any ideas?
thanks
paul
Edited by: paul.schweiger on Mar 4, 2009 10:36 AM
Stupidly used the rich text editor which doesn't seem to work too wellJB,
There actually is a post from the team in this thread ;-)
The patch on 3/30 was not scheduled to fix any other errors other than the import issue we encountered. We included an LDAP fix and a 9i performance query issue. The exact bugs fixed are listed in the check for updates detail before you download the fix.
All bugs can be logged with Metalink, that is the primary place for logging and tracking bugs. The forum is for discussions on how to use the product - for pointers and advice.
Paul,
By your long standing bug, I assume you mean that .pks, pkb and .plb files are opened in the PL/SQL Editor. This has been fixed in 1.5.4.
What has not been done and has been scheduled for 2.0 is the ability to associate any extension with a file and then open that file with the pl/sql editor.
For all encountering the ora-00904 error, this is specifically related to opening PL/SQL in a 9i database and we have a bug logged for that.
Sue
Maybe you are looking for
-
AUR policy on packages with no version in the source file name
I know that the AUR policy says that no code must be included with the PKGBUILD if you are not a trusted user. But, how do you deal with packages that do not have their version number in the file name: http://www.somesite.com/someproject.tar.gz inste
-
How do I delete/remove a completed 'reminder'
I have a completed 'reminder' in iCal that I would like to delete/remove.
-
howdy howdy howdy. is there a way of specifying cells in a jtable to have a different object in each cell. e.g. from the jtable tutorial TableColumn sportColumn = table.getColumnModel().getColumn(2); JComboBox comboBox = new JComboBox(); comboBox.add
-
Removing photo album from desktop
I accidentally moved a photo album to my desktop and would like to remove it. How do I do that?
-
Form Reset When Radio Button Clicked.
I have two radio buttons. One is checked and form elements are visible The second, when clicks, makes all but one form element uneditable When the Second is clicked, I need the form elements to be reset. Any Ideas?