Oracle AND PL/SQL,

1. What is true about the following PL/SQL block.
DECLARE
i NUMBER := 1;
BEGIN
LOOP
dbms_output.put_line (i);
i := i+1;
END LOOP;
END;
An infinite loop.
Will continue printing numbers beginning with 1 until the buffer overflow limit is reached.
both 1 and 2 are correct.
Will give syntax error.
2. How many times is a While loop executed if the test condition always evaluates to FALSE?
Infinte
Will never execute
Will give runtime error
Will give syntax error
3. What is the value of a FOR loop counter after the termination of the loop?
same as lower limit
same as upper limit
Undefined
0 (zero)
4. What types of PL/SQL loops can be nested one inside another?
A simple loop inside a WHILE loop.
A WHILE loop inside a simple loop.
Any loop can be nested inside another loop.
None of the above.

1.
True - Will continue printing numbers beginning with 1 until the buffer overflow limit is reached.
2.
No actual code for this question. Can't say which statement is TRUE.
3.
No actual code for this question and it depends as to what you will be using for the nth numbers.
4.
True - Any loop can be nested inside another loop.

Similar Messages

  • What are the Basic Differences between Oracle and  MS-SQL server Database?

    Hello,
            anybody pls Guide me about the Differences between Oracle and MS-SQL server Database.and also IBM Databases also
    Regards,
    Balaram

    SQL Server only works on Windows-based platforms, including Windows 9x, Windows NT, Windows 2000 and Windows CE.
    In comparison with SQL Server , OracleDatabase supports all known platforms, including Windows-based platforms, AIX-Based Systems, Compaq Tru64 UNIX, HP 9000 Series HP-UX, Linux Intel, Sun Solaris and so on.
    The SQL Server  advantages:
    SQL Server  holds the top TPC-C performance and price/performance results.
    SQL Server  is generally accepted as easier to install, use and manage.
    The Oracle  Database advantages:
    Oracle  Database supports all known platforms, not only the Windows-based platforms.
    PL/SQL is more powerful language than T-SQL.
    More fine-tuning to the configuration can be done via start-up parameters.
    Samrat

  • Real-Time Data Sync-up between Oracle and MS SQL Server

    Hi All,
    I am looking for a solution to sync-up the data between Oracle and MS SQL Server in real time. Here, the structure of table is different (in the sense, the data in multiple table in SQL Server should be combined and put it in a single table in Oracle and vice versa).
    Could anybody throw light on this plz?
    Thanks in advance!

    mt**** wrote:
    Hi All,
    I am looking for a solution to sync-up the data between Oracle and MS SQL Server in real time. Here, the structure of table is different (in the sense, the data in multiple table in SQL Server should be combined and put it in a single table in Oracle and vice versa).
    Could anybody throw light on this plz?
    Thanks in advance!Handle:     mt****
    Status Level:     Newbie
    Registered:     Feb 9, 2003
    Total Posts:     183
    Total Questions:     14 (10 unresolved)
    why so MANY unanswered questions?
    what should occur when DML occurs & the "other" DB is not online?

  • Join ResultSet fra Oracle and MS SQL?

    I currently looking for documentation on how to JOIN ResultSet fra two different databases?
    Currently, we use a Oracle DB for some information, and MS SQL for some other type of information which is related to each other. Don't ask why, this is a program for some client.
    I'm having a hard time to find information on how to combine two ResultSet's like described above. Can anyone lead me in the correct direction?
    Thanks!

    I think you may be able to set up a link between the two databases at the database level. My terminology may be off but I think this is essentially "federated data".
    Your best bet is to leverage the power of your DB systems to do the hard work for you. Once you can see the data from one from within the other, you should be able to query the data as though it was all on the same system.
    I don't know how viable this is but it might be a place to start.

  • Oracle and MS sql

    hi
    Is it possible to create a trigger in oracle so that when a row is inserted in a table it execute a stored procedure in MS sql server?
    Thanks

    Probably.
    You might have to create a manual solution, something like inserting a row in a table which a process will periodically wake up and read extracting the data from Oracle and manually loading it into MS

  • Comparing Oracle and MS SQL Server 2005

    Hi!
    I'm looking for documents which compare
    features, price etc og the database and database related development-projects
    I'm looking for resources that describe the terminology used of MS and Oracle for their db's.
    I'm also looking for "Feuerstein"-best-practices in MS-world.
    And at last I'm looking for simple and complex scenarios comparing performance/features of these db's.
    And if possible, I want them from some "independent" sources...
    Can anyone help?
    Best regards
    Bjorn Dorr Jensen

    Hi Hans!
    I think it would not be fair comparing Oracle 10g with SQL Server 2000.
    So thats why I'm looking for comparison with SQL Server 2005,
    but if you have something that compare Oracle 11 with SQL Server 2005,
    let me hear about it :-)
    The objective:
    well, the last 2 years I worked with Oracle DB (tuning, pl/sql) in an serious manner.
    and now I have to work with SQL Server (which I didn't work with the last 2 years),
    so I'm interested in the differences.
    For now it seems that many SQL Server features are primitive compared with Oracle, but Microsofts usability is much better.
    O1.) But is it really more primitive or are I'm missing the nessessary experience with SQL Server? Thats some of the points I want to find out.
    O2.) Analyzing our own requirements for features: when would it be better to use Oracle and when to use MS? How to make this measure-able?
    Could one make an descision tree like:
    when more than x users/day and clustering needed and db_size>y....
    O3.) Should I promote in an environment with people only using MS-products,
    promote the use of Oracle-DB? When will this be an good idea?
    (I don't think it will be an good idea the other way around: moving from Oracle to MS SQL Server - or would it ;^)
    Best Regards
    Bjorn

  • SOS!! HBC's pointing ORACLE and MS-SQL server DB simultaneously  Help!!!!!

    Dear Partners:
    Switching the Model.jpr->Business Components->Connections between
    2 different DB connections (1) Ms-Sql server and (2) Oracle, I was able
    to create Entity-and-View BC's from both databases. Also, I was able
    to drag and drop datacontrols (tables) from both databases over
    the same JSP/UIX page.
    However, the application runs working only with either the MS-sql-BC's or
    the Oracle-BC's, but not both simultaneously.
    I beg your help to solve this issue.

    I think you'll need 2 AMs for this to work. Each AM will have it's own DB connection. Unless one DB knows how to access the other DB's tables (using something like the Oracle Transparent Gateway).

  • Oracle and MS SQL Server

    Hello All,
    SQL Server is on Windows and our oracle is on Unix.
    Now i want to use Hetrogenous Service of oracle to pull data which requires me to connect to system dsn. Now i create a system dsn in windows. How should the HS_FDS_CONNECT_INFO value set point sysetm dsn on windows system.
    Regards,
    Ron.

    Do you have a metalink account? If so, try a search there. The first time I tried this, I found the docs on metalink very useful for setup and for troubleshooting later.
    That being said, going the other way is much easier. Using DTS on SQL Server to pull data from Oracle only requires the 2 "layers" that already exist without having to set up a listener in between to simulate SQL Server as an Oracle instance. This may not be the case in all configurations, but was in my experience.

  • How to create ODBC connection between Oracle 10g and MS SQL Server

    Hi,
    Can someone help us with the steps to create an ODBC connection between Oracle APPS using Oracle 10g database and MS SQL Server.
    Requirement is to extract the transactional data from MS SQL Server on a daily basis and dump it into Oracle tables for an interface to be run. Currently it is being done through Dataloader tool which we feel is causing the data issue with Arabic characters. We want to create the ODBC directly between Oracle and MS SQL Server and check if the data is being pulled correctly.
    The data is in sql server 2000 which has data in Arabic_CI_AS character set which is moved to Oracle 10.2.0.3 database with characterset AL32UTF8. The table data is moved to oracle using the dataloader 3.6 standard edition licensed version. We cannot change the character set of Sql Server 2000.
    Please help
    Thanks
    Shanil

    Hi,
    If you're trying to PULL data from SQLServer into an Oracle database, you wouldnt use Oracle ODBC driver for that, so you may want to post in the Heterogeneous Services forum instead:
    Heterogeneous Connectivity
    If you're trying to PUSH data from SQLServer into an Oracle database, you could use ODBC but most folks use OLEDB for that, and the following note on MOS should help:
    How to Create a Sql Server Linked Server With The Oracle Provider for OLE DB     (Doc ID 191368.1)
    As with any NLS related issue, the first thing to do is dump the codepoints of the data in the Oracle database to see if it is stored validly, rather than relying on what the data "looks like" from some tool or other. It's best to check a single row, with only a few characters in it if you can, and you can do that via
    SELECT DUMP(<columname>,1016) FROM <tablename> WHERE ...
    Hope it helps,
    Greg

  • Hetrogeneoues connection between Oracle and SQL server

    Hi ,
    I am having Issues in Making Heterogeneous  DB link between Oracle Xe and sql server .
    Here is the scenario-
    My Oracle and ms SQL 2003 are running on same machine(windows 2003) ,
    I have followed this link and reached till 5 but I am not able to tnsping the SQLSERVER DNS entry .
    http://www.databasejournal.com/features/oracle/article.php/3442661/Making-a-Connection-from-Oracle-to-SQL-Server.htm
    Below are my lintener and tnsfiles
    LISTENER.ORA
    ===========================================================================================================================================================
    SID_LIST_LISTENER =
      (SID_LIST =
        (SID_DESC =
          (SID_NAME = PLSExtProc)
          (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
          (PROGRAM = extproc)
        (SID_DESC =
          (SID_NAME = CLRExtProc)
          (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
          (PROGRAM = extproc)
           (ENVS = "EXTPROC_DLLS=ONLY:C:\oraclexe\app\oracle\product\11.2.0\server\bin\OraClr11.dll")
    LISTENER =
      (DESCRIPTION_LIST =
        (DESCRIPTION =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
          (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    LISTENERSQL =
    (ADDRESS_LIST=
          (ADDRESS=(PROTOCOL=ipc)(KEY=PNPKEY))
          (ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1522))
    SID_LIST_LISTENERSQL=
      (SID_LIST=
          (SID_DESC =
           (SID_NAME = SQLSRVRDBLNK)
           (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
           (PROGRAM = hsodbc)
    ===========================================================================================================================================================
    TNSNAMES.ORA
    XE =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = testenviroment)(PORT = 1521))
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = XE)
    EXTPROC_CONNECTION_DATA =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
        (CONNECT_DATA =
          (SID = PLSExtProc)
          (PRESENTATION = RO)
    ORACLR_CONNECTION_DATA =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
        (CONNECT_DATA =
          (SID = CLRExtProc)
          (PRESENTATION = RO)
    SQLSRVRDBLNK  =
      (DESCRIPTION=
    (ADDRESS=  (PROTOCOL=tcp)(HOST=localhost)(PORT=1522))
    (CONNECT_DATA=(SID=SQLSRVRDBLNK)
      (HS=OK)
    ========================================================================================================================================================
    Listner Status
    C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN>lsnrctl status LISTENERSQL
    LSNRCTL for 32-bit Windows: Version 11.2.0.2.0 - Production on 19-JUL-2013 13:15:59
    Copyright (c) 1991, 2010, Oracle.  All rights reserved.
    Connecting to (ADDRESS=(PROTOCOL=ipc)(KEY=PNPKEY))
    STATUS of the LISTENER
    Alias                     LISTENERSQL
    Version                   TNSLSNR for 32-bit Windows: Version 11.2.0.2.0 - Production
    Start Date                19-JUL-2013 12:17:39
    Uptime                    0 days 0 hr. 58 min. 24 sec
    Trace Level               off
    Security                  ON: Local OS Authentication
    SNMP                      OFF
    Listener Parameter File   C:\oraclexe\app\oracle\product\11.2.0\server\network\admin\listener.ora
    Listener Log File         C:\oraclexe\app\oracle\diag\tnslsnr\testenviroment\listenersql\alert\log.xml
    Listening Endpoints Summary...
      (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\PNPKEYipc)))
      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1522)))
    Services Summary...
    Service "SQLSRVRDBLNK" has 1 instance(s).
      Instance "SQLSRVRDBLNK", status UNKNOWN, has 1 handler(s) for this service...
    The command completed successfully
    =========================================================================================================================================================
    Now If I try to Tnsping SQL heterogeneous connection , i get
    C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN>tnsping SQLSRVRDBLNK
    TNS Ping Utility for 32-bit Windows: Version 11.2.0.2.0 - Production on 19-JUL-2013 13:17:47
    Copyright (c) 1997, 2010, Oracle.  All rights reserved.
    Used parameter files:
    C:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION=
    TNS-12533: TNS:illegal ADDRESS parameters
    Need Help , please suggest
    Thanks,
    Manish

    Hi ,
    Thanks for the update I have changed the Listener as suggested , now my Listener File is
    SID_LIST_LISTENER =
      (SID_LIST =
        (SID_DESC =
          (SID_NAME = PLSExtProc)
          (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
          (PROGRAM = extproc)
        (SID_DESC =
          (SID_NAME = CLRExtProc)
          (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
          (PROGRAM = extproc)
        (SID_DESC =
           (SID_NAME = SQLSRVRDBLNK)
           (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
           (PROGRAM = hsodbc)
           (ENVS = "EXTPROC_DLLS=ONLY:C:\oraclexe\app\oracle\product\11.2.0\server\bin\OraClr11.dll")
    LISTENER =
      (DESCRIPTION_LIST =
        (DESCRIPTION =
          (ADDRESS_LIST=
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
          (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.60.146)(PORT = 1521))
          (ADDRESS=(PROTOCOL=ipc)(KEY=PNPKEY))
          (ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1522)))
    ========================================================================================================================
    and tns entry 
    SQLSRVRDBLNK  =
      (DESCRIPTION=
    (ADDRESS=  (PROTOCOL= TCP)(HOST=192.168.60.146)(PORT=1522))
    (CONNECT_DATA=(SID=SQLSRVRDBLNK)
      (HS=OK)
    ========================================================================================================================
    Restarted the listener
    C:\Documents and Settings\Administrator>lsnrctl start LISTENER
    LSNRCTL for 32-bit Windows: Version 11.2.0.2.0 - Production on 20-JUL-2013 12:27:38
    Copyright (c) 1991, 2010, Oracle.  All rights reserved.
    Starting tnslsnr: please wait...
    TNSLSNR for 32-bit Windows: Version 11.2.0.2.0 - Production
    System parameter file is C:\oraclexe\app\oracle\product\11.2.0\server\network\admin\listener.ora
    Log messages written to C:\oraclexe\app\oracle\diag\tnslsnr\testenviroment\listener\alert\log.xml
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC1ipc)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.60.146)(PORT=1521)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\PNPKEYipc)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1522)))
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))
    STATUS of the LISTENER
    Alias                     LISTENER
    Version                   TNSLSNR for 32-bit Windows: Version 11.2.0.2.0 - Production
    Start Date                20-JUL-2013 12:27:44
    Uptime                    0 days 0 hr. 0 min. 5 sec
    Trace Level               off
    Security                  ON: Local OS Authentication
    SNMP                      OFF
    Listener Parameter File   C:\oraclexe\app\oracle\product\11.2.0\server\network\admin\listener.ora
    Listener Log File         C:\oraclexe\app\oracle\diag\tnslsnr\testenviroment\listener\alert\log.xml
    Listening Endpoints Summary...
      (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC1ipc)))
      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.60.146)(PORT=1521)))
      (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\PNPKEYipc)))
      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1522)))
    Services Summary...
    Service "CLRExtProc" has 1 instance(s).
      Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Service "PLSExtProc" has 1 instance(s).
      Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Service "SQLSRVRDBLNK" has 1 instance(s).
      Instance "SQLSRVRDBLNK", status UNKNOWN, has 1 handler(s) for this service...
    The command completed successfully
    ========================================================================================================================
    Still Getting the same Error
    C:\Documents and Settings\Administrator>tnsping SQLSRVRDBLNK
    TNS Ping Utility for 32-bit Windows: Version 11.2.0.2.0 - Production on 20-JUL-2013 12:27:52
    Copyright (c) 1997, 2010, Oracle.  All rights reserved.
    Used parameter files:
    C:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION=
    TNS-12533: TNS:illegal ADDRESS parameters
    C:\Documents and Settings\Administrator>
    ========================================================================================================================
    Do we need to change any thing in sqlnet.ora file for heterogeneous connection?
    Thanks ,
    Manish

  • I need step by step way to make replication between oracle and sql server

    I succeeded in make dblink between oracle and microsoft sql
    and I try to insert data using dblink to microsoft sql
    what will I do now to make replication between them

    how to configure my apply process to work with sql server by getway , I want to make replication
    note :
    I make dblink between oracle and sql and make insert from oracle to sql
    is it sufficient to make replication by OEM between oracle and oracle and then add new apply process to work with gateway for sql server and how ?

  • Oracle Vs Ms Sql Server to handle around 6-7 Terabytes of data

    I am considering Oracle 11G to handle around 6-7 Terabytes of data. This data will get accumulated over a period of 8 Months. Any data older then 8 months is purged out of the database.
    Some of my MS SQL DBAs are saying SQL server offers similar performance at a very low cost. Is this really true? On What basis or parameters I can compare Oracle with MS SQL Server to nullify the price advantage?
    I am not looking for ease of development, I am purely looking in terms of handling the huge data and still be able to provide good performance. Apart from performance if there is any parameter which makes any difference then please highlight.

    As with any database requirements tend to drive the best technology to utilize.
    I have run Oracle and MS SQL Server as well as MySQL and PostgreSQL.
    If you are looking to support a fairly large user based on a database that is 6-7 TB is size where a good portiion of the data is subject to access then there is really is no comparison. Oracle does a much better job of handling large user bases with large data sets then MS SQL Server or MySQL at least based on my experience with them.
    MySQL works very well for average user bases and smaller databases where the amount of data accessed is small. In other words you can have 6 TB of data and if you only frequently access 5GB of it then MySQL will work pretty well. If a large portion of the data is accessed all the time by many users you will struggle with MySQL. Most databases in MySQL I ran had issues at user bases of a few hundred with a database size of around 100G-200G, now my main expertise is in Oracle so there may be ways in MySQL to address this, but not easily as normal research and experiment channels did not yeild good results for me.
    I have had a MS SQL Server databases with thousands of users fall on it face with a database only 20GB in size, its was completely CPU bound with 8 CPUs, then moved the database to Oracle with minor code changes to accommidate the differences between Oracle and SQL server using the same hardware specs and CPU was a steady 50% for the same work load and basically the same application.
    I have found the capabilities of Oracle for large data sets and large users provide advantages that the other databases just did not offer or did not do well enough to overcome. Does not mean that Oracle is perfect, or the other databases are bad, but there are a lot of options and capabilities in oracle the I can take advantage of not to mention if I need to I can run on high end Unix hardware and goto 64CPU dozens of I/O channels, etc. I can not do that with MS SQL Server as Windows is my only option and the intel platform just does not hit the capabilties of higher end Unix Hardware.
    When deciding the database to use cost should be the last factor used. If the database will not do what you need it to do then low cost does not help you. Deteremine the needs and requirements and then examine the database features and capabilities to determine what might work best for your situation. If it is a critical business function and you need the caddie then your business will pay for the caddie, it if needs a malibu then pay for the malibu or if it needs the yugo then pay for the yugo. Implement the right technologies where you need them. However there is something of an advantage to limit the number of technologies you will need to support as a jack of all trades never becomes an expert and that in of itself can be costly when trying to overcome issues developed by limitations of a database technology.

  • JDBC and MS SQL Server support

    Hi everyone,
    I'm using JDBC to access a MS SQL Server DB. To be more precise, I tried both the MS JDBC SQL Server driver as well as jTDS. Here's the question:
    I'm using scrolling and committable cursors. My application could definetely make good use of full detection of inserted, updated and deleted rows - that is, I would like to use
    ResultSet.rowInserted()
    ResultSet.rowUpdated()
    ResultSet.rowDeleted()
    to automatically detect each row's status. The problem is the following:
    DatabaseMetaData.insertsAreDetected() returns false
    DatabaseMetaData.updatesAreDetected() returns false
    DatabaseMetaData.deletesAreDetected() returns true
    i.e. I can only detect deletes using either of the two above mentioned drivers.
    Of course, I could construct an enhanced ResultSet class mimicking the behaviour I want, but I'd rather not.
    The question is: Does anyone know a JDBC MS SQL Server driver supporting automatic insert, update AND delete detection?
    If so, please give me a pointer.
    TIA,
    Carsten

    I am in serious problem.
    Jdbc doesnot support database connections without DSN.
    Oracle and MS SQL Server 2000 both provides ADO for
    connecting with their databases without DSN. But Java
    doesnot support ADO.
    Can anyone help me out?
    I never use a DSN when connecting to Oracle. Nor is ADO used.
    But then I do use the drivers that Oracle supplies.
    And there are a number of MS SQL Server drivers, and they don't use DSN nor do they use ADO.

  • Installing with Oracle or MS-SQL

    Hello,
    Is there a PDF or some page with the necessary setup to install LiveCycle ES Reader Extensions with Oracle and MS-SQL Server?
    Thank you for any info.
    Marcos

    Hi Srikant,
    I have worked on similar stuff, but the scenario was a little different. I worked on creating Web Services using EJBs, but the basic part was that, the web service was supposed to interact with the SQL Server database. So maybe I can help you...
    First thing which is needed is that you have created the JDBC Connector in your Visual Administrator correctly. If you wish to cross check, you can see my answer in the following thread:
    JDBC error
    In this thread itself I have given the code which is the solution to your problem (this is what i believe). I am pasting the code again:
    <b>InitialContext initialContext = new InitialContext();
    DataSource dataSource = (DataSource)initialContext.lookup("jdbc/MyAlias");
    java.sql.Connection connection = dataSource.getConnection();</b>
    You can use this code in the method of your EJB, and then you can easily use this connection object to access your database tables using SQL queries.
    And if by any chance you are looking for a step wise procedure for creating a web service from an EJB, then give me your email address, i will send you the doc.
    Bye
    Ankur
    Do reward points if it helps!!

  • Matching data types b/w oracle and sql server

    anyone here knows if there is a list of data types supported by both oracle and sql server (regardless of releases & versions?
    an immediate response would be highly appreciated.
    thanks.

    Hi,
    The following post might be of assistance to you:
    http://msdn.microsoft.com/en-us/library/ms151817.aspx
    If this is what you're looking for, then mark the question as answered and closed.
    Regards,
    Naveed.

Maybe you are looking for

  • How to send original filename as the attachment name through mail adapter?

    Hi, I have a File to Mail scenario where the file is picked up from a folder in R/3 system and is sent as an attachment through mail. The requirement is to send the file unconverted and with the same file name. When tried without creating any ESR obj

  • When uploading photos from PC to iPhoto,

    hi, i am a new mac user, so am slowly finding my way. i am currently transferring photos from my PC over to iphoto. what I want to know is do i need to save the photo folder on hard drive if they are already uploaded into iPhoto? also, where does iph

  • Limiting JTextField to 4 characters only

    I'm making an interface to allow the user to enter 4 groups of 4 digits. This is made up of 4 JTextFields, that when the user has entered the fourth digit in box 1 the interface automatically jumps to box 2 etc, usual stuff. The problem I'm having is

  • Set Assigned to in case from user input form

    Hi there Can anyone tell me if you can set the case Assigned to property from a user input field. Like you can set a category <input type="text" value="Client App id tag" maxlength="255" id="CAT_Category" name="CAT_Category" class="cat_textbox_small"

  • How old do I have to be to call apple?

    I need to reset my security question answers