Oracle Database 11g Express Editionへの接続について

Oracle Database 11g Express Editionを自PCにインストールし、SQLPLUS等の接続
まで確認する事ができました。
その後、VB2008で開発を行っている事から、VB2008で接続しようと考えていますが、
どのような接続方法が最適なのでしょうか???
当然、最終的にはクライアント/サーバ型にしたいと考えている為、クライアントからの接続
も想定しています。
ODBCは避けたく、他に方法を探していたところ、ODP.NETで接続できると記載が
あった為、同自PCにインストールし、接続を行おうと記述したところ下記のようなエラー
となってしまいます。
《記述内容》
 'Connectionオブジェクトの生成
 Dim cnn As New OracleConnection
 Dim Command As OracleCommand
'Oracleへのコネクションの確立
cnn.ConnectionString = _
"User Id=ABCD; Password=000000; Data Source=XE"
cnn.Open()
Command = cnn.CreateCommand
'SQL初期化
Command.CommandText = ""
'データリーダーにデータ取得
Command.CommandText = "SELECT COUNT(*) FROM T_東京"
《エラー内容》
 ORA-12154: TNS: 指定された接続識別子を解決できませんでした
”tnsping XE”は確認しており、問題なくとおります。
そもそも私の考え方が間違っていて、ODP.NETは使用できない???
記述の方法が間違っている???
初歩的な質問で申し訳ありませんが、教えて頂きたいと思います。
よろしくお願いします。

.netアプリを作成しているならばODP.netでの接続がベストだと思います。
ORA-12154が発生するのは参照しようとしているtnsnames.oraの中に"XE"という接続定義が見つからないためと思われます。
tnspingでは問題なく疎通できる+ODP.netを追加インストールしたとのことから
odp.netをインストールしたORACLE_HOME配下のtnsnames.oraにXEという定義がないのだと思います。
(XEのORACLE_HOME配下のtnsnames.oraにのみXEの定義がされている)
ちなみに、tnsnames.oraは以下にあります。
%ORACLE_HOME%\NETWORK\admin\tnsnames.ora
そもそも私の考え方が間違っていて、ODP.NETは使用できない???
ORA-12154が発生するところまで進んでいるのでODP.net自体は使用できています。
ODP.net自体が使用できない状態だと OracleConnectionオブジェクトの生成の時点でエラーになるはずなので。
あと、tnsnames.oraを参照しないで接続できる簡易接続ネーミングという記載方法もあります。
例)
Data Source=localhost:1521/XE
参考
http://www.doppo1.net/oracle/beginner/network_connect_2.html

Similar Messages

  • How to install oracle database 11g express edition on Windows 7

    Hi Guys,
    i am trying to download and install Oracle database 11g express edition on windows7 and i can't seem to get it right. i did get the download but when i try to install, it keeps saying it appears to be an invalid archive.
    Please help..

    Action - Refer to the logs or contact OracleFinding the problem is the key. "Refer to the logs" is the only option, XE has no oracle support offerings.
    Which plugin failed, and why did it fail will be important clues. There should be error messages in the log that will be helpful.
    Otherwise, we don't have much help to offer. Fixing a problem means identifying the problem and performing steps to correct it, if there a fix is available.
    A MOS lookup on the ins-20802 error has snippets from one installer session, this one is from an x64 install. Not x86. To paraphrase the details:
    ... Created a new file <drive>:<OH path>\cfgtoollogs\configToolAllCommands
    SEVERE: java.io.IOException: Access is denied
    ...So from those symptoms, the user trying to run the installer does not have appropriate rights on that drive and/or folder. The fix for that particular problem is adding the user to the local administrators group. And rerunning the install. After running the deinstall steps to clean up the installation. As specified in the XE install guide for Windows.
    http://docs.oracle.com/cd/E17781_01/install.112/e18803/toc.htm
    Also note the System Requirements, it specifies a System architecture Intel x86, which is not X64. There is no X64 installer for XE on Windows. So it might work. Or it might not if your host is x64.
    So if that is your particular error, verify that your user is in the local admins group. Either use the local users and groups applet (Start/Run/lusrmgr.msc) and open up the Administrators group. Click the Add button. Find your user. If your OS user is a windows domain user, be sure you have authenticated to the domain.
    Try the `net ...` list of the adminis group, that should reveal whom is indeed in the local administrators group:
    net localgroup administrators
    Administrator
    <domain>\Domain Admins ... # ??? is the host in windows domain ???
    <domain>\Local Admins
    <domain>\<user1>
    <user2>
    <user3>
    echo %USERNAME%
    # if relevant:
    echo %USERDOMAIN%Like it also states in the Windows install guide, under Permission Required quote:
    ... must be a member of the Administrators group on Windows to install Oracle Database XE.

  • Error while opening Oracle Database 11g Express Edition after installation.

    After finishing the installation of Oracle database 11g Express Edition, when I tried to open it, it shows following error : windows cannot find `http://127.0.0.1:%HTTPPORT%/apex/f?p=4950`.Make sure you typed the name coorectly, and then try again.
    What the above error means? I followed the installation steps as given in the link.

    Hi,
    Follow thread may help you.
    <<Newbie on running Oracle 11g - Windows cannot find http:something
    Regards,

  • Oracle Database 11g Express Edition (11.2) Beta is now available!

    [url http://forums.oracle.com/forums/forum.jspa?forumID=1378]Forum Home » Database » Oracle Database 11g Express Edition Beta ばかりじゃなんなので、
    Forum Home » コミュニティ » OTNカフェ に [url http://forums.oracle.com/forums/thread.jspa?threadID=2201589]Thread: Oracle Database 11g Express Edition (11.2) Beta is now available! を作ったのですが、この Japanese Discussion Forums にも、めでたく この [url http://forums.oracle.com/forums/forum.jspa?forumID=1380]Forum Home » データベース » Oracle Database 11g Express Edition Beta ができましたので、OTNカフェの Thread をこの Threadへ引越しました。
    既に OTN Japan の [url http://www.oracle.com/technetwork/jp/database/express-edition/overview/index.html]Oracle Technology Network > Database Database > Express Edition > Overview にも載っていますが、[url  http://www.oracle.com/technetwork/database/express-edition/11gxe-beta-download-302519.html]http://www.oracle.com/technetwork/database/express-edition/11gxe-beta-download-302519.html から " Oracle Database 11g Express Edition Release 11.2.0.2.0 - Beta "がダウンロードできます。
    [url http://forums.oracle.com/forums/forum.jspa?forumID=1378]Forum Home » Database » Oracle Database 11g Express Edition Beta を見てみたり、コメントしてフィードバックするのを楽しんでます。
    【補足】
    現行リリース Oracle Database 10g Express Edition ( 俗称 Oracle Database XE や Oracle XE や OracleXE )関連 Oracle Technology Network (OTN) Japan - 掲示板 » コミュニティ » OTNカフェ のスレッドなど :
    [url http://otn.oracle.co.jp/forum/thread.jspa?threadID=5001436]Oracle 10g Express Editionに興味深々
    [url http://otn.oracle.co.jp/forum/thread.jspa?threadID=5001550]Oracle Database 10g Express Edition Beta 3
    [url http://otn.oracle.co.jp/forum/thread.jspa?threadID=35004868]OracleXEに関する座談会
    "Project XE" (Oracle Database XE in Japan) - S/N Ratio (by SATO Naoki) [url http://d.hatena.ne.jp/satonaoki/20081202/p1]http://d.hatena.ne.jp/satonaoki/20081202/p1
    Edited by: wmo6hash on Apr 24, 2011 3:45 AM Blogosphere は別の Message へ

    そうですね。Oracle Database 11g Express Edition BetaフォーラムなのでBetaのことだけ書いていました。

  • Problem in installing oracle database 11g express edition

    while installing oracle database 11g express edition during product specific prerequisite check, checking for oracle XE service instance is failed, what to do ?

    Hello, and welcome to the OTN forums,
    the prerequisites are documented quite well. I'm not sure about the actual error message, but from what you write it sounds like you already have another Oracle XE install on your machine, possible the Oracle 10g XE. As mentioned in the Installation Guide, you may have only one instance per server, so the installer fails.
    If that's not the reason, can you please post the exact error message you receive?
    -Udo

  • VSS for Oracle Database 11g Express Edition?

    I use Veeam to backup our servers.
    I have a Windows 2003 R2 Std edition. On it we have Oracle Database 11g Express Edition (upgraded from 10g).
    I would like to enable application-aware image processing (VSS)
    I do not have the Oracle VSS Writer Service installed, and the oravssw.exe is not in the oracle folder.
    1. Does Oracle Database 11g Express Edition support/include Oracle VSS Writer?
    2. If I get the oravssw.exe from another (not express) oracle database, can I copy it and use it on my 11g Express Edition to create the Oracle VSS Writer?
    Thanks in advance

    909351 wrote:
    Thanks. So I guess I will have to use 10g XE on my 32 bit Linux
    Its interesting 10g XE was for 64 bit and 11g XE is for 32 bit.The other way around. 10.2 is 32-bit and 11.2 is 64-bit. Seems like a logical or natural progression (haven't seen a 32-bit machine for some years now).

  • Oracle DB 11g Express Edition Find directory home path in Windows 7

    Hello,
    I am working through a PL/SQL Programming book and I am on PROGRAM UNIT DEPENDENCIES. As I work through the examples it asks me to use the Dependency Tree Utility by running this script in SQL*Plus: @<path to Oracle Home directory>\rdbms\utldtree
    However, no matter where I look on my computer (Win7 Home) I cannot figure out the directory path. I looked elsewhere and it was suggested that Windows stores the directory in the registry. I went to regedit and followed Hkey_Local_Machine\Software\Oracle....and found 'c:\oraclexe\app\oracle\product\l11.2.0\server'
    I tried that as the directory path, but no luck. Plus I cannot even find any file folders for the DB that contains 'rdbms'.
    So my question is, is there a directory HOME or BASE path in windows 7 for Oracle database 11g Express Edition and or does the 11g Express Edition have the utldtree.sql file somewhere?
    Thanks in advance for any help,
    Warren

    I have a lot of utl*.sql files, including the one you named, in C:\oracle\oraclexe\app\oracle\product\11.2.0\server\rdbms\admin.
    You should also be able to reach the location when running in sqlplus, via "?" shortcut, e.g.
    SQL> @?/rdbms/admin/utldtree
    There's also a way to print top dir of Oracle Home in sqlplus - e.g. path inside square brackets below:
    SQL> @.[%oracle_home%].
    SP2-0310: unable to open file ".[C:\oracle\oraclexe\app\oracle\product\11.2.0\server]..sql"

  • Problem upgrading Apex 2.1 to 3.2.1 in Oracle Database 10g Express Edition

    G'Day Apex gurus,
    I installed Oracle Database 10g Express edition in my Windows XP PC which comes with Apex 2.1 with no problems. Then I wanted to upgrade Apex 2.1 to 3.2.1 (Currently Apex download in OTN) following the document below:
    http://www.oracle.com/technology/products/database/application_express/html/3.1_and_xe.html
    I went to the steps:
    @apexins SYSAUX SYSAUX TEMP /i/
    Then to change the password for the admin account run apxchpwd.sql and when prompted enter a password for the ADMIN account.
    @apxchpwd
    with not problems
    Then I connected to SQL*Plus as SYS by:
    sqlplus /nolog
    CONNECT SYS as SYSDBA
    Enter password: xxxxxxxxxxx
    but when I tried to run:
    @APEX_HOME/apex/apxldimg.sql APEX_HOME
    where APEX_HOME is Apex3.2.1 in my case
    SQL> @Apex3.2.1/apex/apxldimg.sql Apex3.2.1 (I get the messages below)
    PL/SQL procedure successfully completed.
    old   1: create directory APEX_IMAGES as '&1/apex/images'
    new   1: create directory APEX_IMAGES as 'Apex3.2.1/apex/images'
    Directory created.
    declare
    *+
    ERROR at line 1:
    ORA-22288: file or LOB operation FILEOPEN failed
    The system cannot find the path specified.
    ORA-06512: at "SYS.DBMS_LOB", line 523
    ORA-06512: at "SYS.XMLTYPE", line 287
    ORA-06512: at line 15
    PL/SQL procedure successfully completed.
    PL/SQL procedure successfully completed.
    Commit complete.
    timing for: Load Images
    Elapsed: 00:00:00.17
    Directory dropped.
    Can anyone help me in how to trouble shout this?
    I tried to continue by following the steps document
    @APEX_HOME/apex/apxxepwd.sql password
    (where password is the password of the Application Express internal ADMIN account)
    but when I tried to login in:
    http://localhost:8080/apex/f?p=4550:1
    when I type the credentials
    system
    system
    systempassword
    nothing happens
    or even If I try:
    http://localhost:8080/apex/f?p=4550:10
    admin
    adminpassword
    nothing happens here too.
    I appreciate any help
    Kind regards
    Carlos

    My database version is 10.2.0.1.0 Oracle express.
    Operating system is Windows Vista.
    I started installing using the following commands.
    @ C:\temp\apex\apexins.sql
    it prompts me for the values of sysaux sysaux temp and c:\temp\apex\images\
    If I supply the value for images the sqlplus window closes after scrolling a lot of info.
    Enroute it also prompts me for a value for 9:
    I don't know what the input shall be.
    Then it again stops at enter value for version:
    I used 3.2.1.0
    The window scrols a while and closes.
    later I changed the password and ran the command.
    @c:\temp\apex\apxldimg.sql c:\temp
    but no success with installation.
    the output is as following.
    SQL*Plus: Release 10.2.0.1.0 - Production on Fri Nov 27 18:13:43 2009
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    SQL> connect system/sairam as sysdba;
    Connected.
    SQL> @ c:\temp\apex\apxchpwd
    Enter a value below for the password for the Application Express ADMIN user.
    Enter a password for the ADMIN user []
    Session altered.
    ...changing password for ADMIN
    wwv_flow_security.g_security_group_id := 10;
    ERROR at line 3:
    ORA-06550: line 3, column 5:
    PLS-00201: identifier 'WWV_FLOW_SECURITY.G_SECURITY_GROUP_ID' must be declared
    ORA-06550: line 3, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 4, column 5:
    PLS-00201: identifier 'WWV_FLOW_SECURITY.G_USER' must be declared
    ORA-06550: line 4, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 5, column 5:
    PLS-00201: identifier 'WWV_FLOW_SECURITY.G_IMPORT_IN_PROGRESS' must be declared
    ORA-06550: line 5, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 8, column 23:
    PL/SQL: ORA-00942: table or view does not exist
    ORA-06550: line 7, column 15:
    PL/SQL: SQL Statement ignored
    ORA-06550: line 13, column 32:
    PLS-00364: loop index variable 'C1' use is invalid
    ORA-06550: line 12, column 9:
    PL/SQL: Statement ignored
    ORA-06550: line 19, column 5:
    PLS-00201: identifier 'WWV_FLOW_SECURITY.G_IMPORT_IN_PROGRESS' must be declared
    ORA-06550: line 19, column 5:
    PL/SQL: Statement ignored
    Commit complete.
    SQL> @c:\temp\apex\apxldimg.sql c:\temp
    PL/SQL procedure successfully completed.
    Directory created.
    if wwv_flow_utilities.db_version_is_at_least('11') then
    ERROR at line 32:
    ORA-06550: line 32, column 25:
    PLS-00302: component 'DB_VERSION_IS_AT_LEAST' must be declared
    ORA-06550: line 32, column 3:
    PL/SQL: Statement ignored
    PL/SQL procedure successfully completed.
    if wwv_flow_utilities.db_version_is_at_least('11') then --11g only
    ERROR at line 16:
    ORA-06550: line 16, column 25:
    PLS-00302: component 'DB_VERSION_IS_AT_LEAST' must be declared
    ORA-06550: line 16, column 3:
    PL/SQL: Statement ignored
    Commit complete.
    timing for: Load Images
    Elapsed: 00:00:00.32
    Directory dropped.
    SQL>
    Does this require XE 11 or anything else.
    This will happen even if I supply as following(closing of sqlplus in the begining).
    @ C:\temp\apex\apexins.sql sysaux sysaux temp c:\temp\apex\images\
    Any help.

  • Oracle Database 10g Express Edition & linux Fedora

    Hi guys
    How are you doing?
    I want to ask about my problem which is I can't access to the home page of Oracle Database 10g Express Edition when I press on "Go To Database Home Page" it's open firefox but does not do any thing by the way I try to write the web page http://127.0.0.1:8080/apex on the address bar but firefox give me an error which is "Unable to connect"
    So please when you know the solution post it here step by step "I'm beginner linux user" .
    My distribution is Fedora 14
    ..Thanks a lot
    Saleh

    Was the configure step completed successfully?i.e., did you run
    /etc/init.d/oracle-xe configure after you installed the rpm? This is similar in XE 10g and 11g beta. You can run this again to reenter your configuration parameters, especially concerning HTTP port, and make sure they have the expected values that way.
    Despite that, you could try to (re)start the service, and see if it comes up without errors.
    /etc/init.d/oracle-xe stop
    /etc/init.d/oracle-xe startIf everything doesn't look too bad, you could have a port conflict with another service using port 8080. In that case, you could reconfigure XE to have its HTTP server listening to a different port.
    -Udo

  • Not able to use oracel database 11g express edition ? please help !!!

    after installing oracel database11g express edition , i am not being able to use it ,because when i click on  get started with oracel database 11g express edition it will divert me to ip  http://127.0.0.1:8080/apex/f?p=4950 and after this it show
    Oops! Google Chrome could not connect to 127.0.0.1:8080
    so please help me out , as i am beginner and new to this , so i don't have deep knowledge of this ,so please help me out ,as soon as possible 

    Hi,
    Provide more info like os and its version - https://blogs.oracle.com/shay/entry/10_commandments_for_the_otn_fo
    Did installation complete successfully?
    check if database is up
    start command prompt
    sqlplus / as sysdba
    select open_mode from v$database;
    check the status of listener
    lsnrctl status
    Post the output of above commands here
    Regards
    Yoonas

  • Download problems Oracle Database 10g Express Edition

    Completed download.
    Attempted to start application but cannot find the server.
    Removed the software using add/remove programs.
    Attempted to reinstall but it seems that some applications are still on my system.
    Attempted to remove the application but the add/remove program does not recognized the application
    What can I do.

    Hello,
    I need to install "Oracle database 10g Express Edition" with different database name example dev but it is taking
    default name that is XE and there is no option come during installation where i can put the name of database as per my desire.First, note that you can't install more than one instance of XE per server. Changing the instance name won't help you with that.
    As you've already found out, the installer always creates a database instance with default names. That's part of the "Express" concept: As little configuration as necessary to get a Oracle Database installed with just a few clicks. The second advantage is, that you can also simplify the documentation, as you can forget about several aspects when you don't have to configure them...
    Since you don't have tools like dbca in XE, your only option would be to rename the database once it's created. There are a few threads on that topic in this forum, e. g. {thread:id=403056}.
    But before you start working on that, could you explain why exactly you have to use a different database/instance name?
    And also explain why we use "Oracle database 10g Express Edition" instead of Oracle database 10g. what is the meaning of Express Edition.Why and how should we answer why you picked a certain edition? The most likely cause is license costs: XE is available for free, all others are just free as long as you use the OTN license...
    For an overview, there is a [url http://www.oracle.com/us/products/database/enterprise-edition/comparisons/index.html]Comparison Matrix for Oracle Database Editions.
    I'd furthermore ask why you still use 10g XE instead of the current 11g XE?
    -Udo

  • Can't succesfully install Oracle Database 10g Express Edition on Ubuntu

    Hi,
    I've been trying to install Oracle Database 10g xe on Ubuntu 10.04 and when I execute the .deb package (oracle-xe-universal_10.2.0.1-1.0_i386.deb) I get a quick installation that doesn't ask me for any configuration settings. When the installation is finished I don't get any menu in my Applications menu named "Oracle Database 10g Express Edition" as specified in Getting Started Guide (I only get some items grouped into an category called "Other" (Backup Database, Get Started, Get Started With Oracle Database 10g Express Edition, Go To Online Forum, Read Documentation, Read Online Help, Register For Online Forum, Restore Database, Run SQL Command Line, Start Database and Stop Database). As a consequence I can't access the Oracle Database Home Page.
    In addition when I click on Start Database I get the following message: "Operation failed. josep is not member of 'dba' group".
    I've tried to re-download the packages and to configure it by editing /etc/init.d/oracle-xe but this doesn't solve my problem.
    can you give me some help?
    Thabk you in advance!

    Markus Waldorf wrote:
    Did you run the post-installation?
    $ sudo /etc/init.d/oracle-xe configureYes I've done it but it doesn't seem to work...

  • Oracle Database 10g Express Edition Bugs

    Product:Oracle Database 10g Express Edition
    Title:Tab Order Sequence on Login window
    Description: Tab Order sequence in Login window not proper, it should be proper
    Reproduce Steps:
    - Click on Run Application icon
    - Login Window opened
    - Press the Tab Button

    hi,
    Please, post this on the Oracle DB express FORUM
    when you install it it will create a menu to directly access to it.
    If you are not able to find it, then you can use the link below:
    Oracle Database Express Edition (XE)
    You have to register to see the forum.
    support for 10g express is provided in the mentioned forum.

  • Oracle Database 10g Express Edition

    Does Oracle Database 10g Express Edition allow for more than one database to be created? If yes, then how do I create additional databases?

    Only one database per computer is allowed.
    Read about the XE limitations here

  • [Oracle Database 10g Express Edition] Don't UP

    Hi,
    I've installed the "Oracle Database 10g Express Edition" in my laptop, ThinkPad T60. The installation finish fine or I think that.
    In the event viewer I don't see any error.
    But I cant sing on in SQL/PLUS and I can't go to web config. All services are up.
    The erro when i conect by SQL PLUS are:
    SQL> connect system/PASSWORD as sysdba
    ERROR:
    ORA-12560: TNS:error del adaptador de protocolo
    SQL> connect system/PASSWORD@localhost as sysdba
    ERROR:
    ORA-12514: TNS:el listener no conoce actualmente el servicio solicitado en el
    descriptor de conexión
    I cant found the error becose It happens.
    I uninstall the database, erase the registry of Windows and Install again. But nothing success. I uninstall again, erase the registry, download again from www.oracle.com all continuous one equally.
    Thanks for all!

    SQL*Plus: Release 10.2.0.1.0 - Production on Vie Oct 20 14:47:04 2006
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    SQL> connect / as sysdba
    Conectado a una instancia inactiva.
    SQL> connect sys/PASSWORD@localhost as sysdba
    ERROR:
    ORA-12514: TNS:el listener no conoce actualmente el servicio solicitado en el
    descriptor de conexi¾n
    Advertencia: íYa no estß conectado a ORACLE!
    SQL>
    The Services are UP.
    The name of enviourment varible is oracle_sid but the value is?
    In My PC --> Propierties ---> Advanced Option ---> Enviorurment variable
    System or User?
    Thanks an i waiting for your help

Maybe you are looking for