More Java in SQL: Viewing resources

Okay, I'm trying to load and use apache's soap.jar into my schema from the HTML DB SQL Command Processor. This is the same jar that I have been using within JDeveloper during testing.
The resource seems to load properly, but when I try to reference the classes of the org.apache.soap package, they cannot be found. Can anyone see something I'm missing in my process? Otherwise, does anyone know how to access more information of the resources that have been loaded into the schema (packages, etc.)?
Thanks a bunch in advance,
Jonathan
Process steps below:
(The jar is stored in a table called file_holder with a blob field called file_lob).
1) Create the Java resource object:
create or replace and resolve java resource named "soap" using blob
   select file_lob from file_holder where filename = 'soap.jar';2) Check to make sure it exists and is valid:
OBJECT_NAME     SUBOBJECT_NAME     OBJECT_ID     DATA_OBJECT_ID     OBJECT_TYPE     CREATED     LAST_DDL_TIME     TIMESTAMP     STATUS     TEMPORARY     GENERATED     SECONDARY
soap     -      273057     -      JAVA RESOURCE     18-AUG-05     18-AUG-05     2005-08-18:15:38:58     VALID     N     N     N3) Try to create a Java source using the JAR:
create or replace and compile java source named "JavaTest" as
import org.apache.soap.SOAPException;
public class JavaTest
  public static int returnOne()
       SOAPException se = new SOAPException("test","test");
       return 1;
};4) Check errors. =/
select * from user_errors where name = 'JavaTest';
NAME     TYPE     SEQUENCE     LINE     POSITION     TEXT     ATTRIBUTE     MESSAGE_NUMBER
JavaTest     JAVA CLASS     1     0     0     ORA-29535: source requires recompilation     ERROR     0
JavaTest     JAVA SOURCE     1     0     0     JavaTest:1: cannot resolve symbol     ERROR     0
JavaTest     JAVA SOURCE     2     0     0     symbol : class SOAPException      ERROR     0
JavaTest     JAVA SOURCE     3     0     0     location: package soap     ERROR     0
JavaTest     JAVA SOURCE     4     0     0     import org.apache.soap.SOAPException;     ERROR     0
JavaTest     JAVA SOURCE     5     0     0     ^     ERROR     0
JavaTest     JAVA SOURCE     6     0     0     JavaTest:6: cannot resolve symbol     ERROR     0
.

Hi sekar,
Interesting, you're able to do a 'CREATE TABLE bla...' but are not familiar with 'SELECT'? I would suggest to read some basic stuff about SQL statements. What will you do when the next task is: "Hey, I need a pgm to change these values in the table!"?
Regards,
Guido

Similar Messages

  • Using SQL view From SQL Express in Flex

    Hello All ,  i am new at Flex and yet searching for a basic answere to even more basic question...
    i am currently looking for a way o extract and import SQL views from my SQL Express database ( on my local host) and present it with RIA on desktop, grpahs Charts etc.
    my question is, which way is the best to do so ? 
    need i to use Coldfusion For the Data ?  and then Flex3 For the design ( i.e Graphs)?
    or maybe using another ODBC program for XML file and then Connect it as Data Resource into the flex3 project
    as you must see , i am a bit confused....
    thanks in advance

    Hi,
             If you go for AIR you can directly connect to Database and you can get the data and can be shown graphically ,
             But if you Go for Webapplication(Flex ) then definately u should use some backend like CFC,PHP,JAVA,.Net............ in order to connect to DB and use Remote Objects/HttpService and show the Result Graphically..............

  • Java retrieving SQL dbo. scripts

    Hi all,
    I know this falls more under the SQL Database than java.
    I need to retrieve the Create Scripts of a database's objects.
    georgemc suggested that I retrieve the scripts directly from the database instead of re-generating the scripts from meta-data.
    The method I used to re-generate the table scripts works (but long process),
    but I also need the scripts for Procedures/Functions/Triggers/Views and it is impossible using meta-data.
    So my question for this thread is:
    How do I get the Create Scripts for SQL dbo's,
    What is the method in Java or what is the Query?
    Please help me.
    Thanx in advance

    database dependentSQL Server 2000
    not Java related at allI know, though I would take a chance (People here are very smart)
    Try to ask the question in a forum that is related to your database.I will
    Have asked a DBA already, but stil waiting for reply
    If I am being a pain with regards to this Thread.
    Sorry, but the more places you ask the higher the chance of being answered.
    Still if someone knows please do tell
    even if it is not for SQLServer 2000,
    It will give me some direction as to my next step./

  • PI 7.11 - SXI_CACHE Issue - SQL 0904 - Resource Limit Exceeded

    Hi PI & IBM I Gurus,
    We are having the SXI_CACHE issue in our PI 7.11 SPS04 system. When we try to do the delta cache refresh through SXI_CACHE, it is returning the error SQL 0904 - Resource limit exceeded. When we try to do the full cache refresh, it is getting the issue 'Application issue during request processing'.
    We have cleaned up the SQL Packages with DLTR3PKG command, which did not resolve the issue. We recently performed a system copy to build the QA instance and I observed that the adapter engine cache for the development is presented in the QA instance and removed that cache from there.
    I am not seeing the adapter engine connection data cache in our PI system. The adapter engine cache is working fine.
    All the caches are working fine from the PI Administration page. The cache connectivity test is failing with the same error as I mentioned for the SXI_CACHE.
    Please let me know if you have encountered any issue like this on IBM I 6.1 Platform.
    Your help is highly appreciated.
    Thanks
    Kalyan

    Hi Kalyan,
    SQL0904 has different reason codes ...
    Which one are you seeing ?
    Is the SQL pack really at its boundary of 1GB ?
    ... otherwise, it is perhaps a totally different issue ... then DLTR3PKG cannot help at all ...
    If you should see this big SQL Package, you should use PRTSQLINF in order to see if there is more or less over and over the same SQL in, just with different host variables or so ...
    If the last point should be the case, I would open a message with BC-DB-DB4 so that they can check how to help here or to talk to the application people to behave a bit different ...
    Regards
    Volker Gueldenpfennig, consolut international ag
    http://www.consolut.com http://www.4soi.de http://www.easymarketplace.de

  • Coalesce in a SQL View?

    I have a table as shown below:
    I need to write a sql view that will show 1 row for the ReqNbr and then a column for the related service calls.  For example the result set should look something like this:
    ReqNbr, Call_Numbers
    10010, 0000013147;0000013097;0000013149;
    10592, 0000012994;0000012999;
    and so on.  I need a view that can do this as a function or stored procedure can't be used in the reporting tool that I'm dealing with.  In addition I would like the Service Call to be sorted ASC in the column when returned.
    Any ideas?

    You need to use a stuff operator for this purpose... see this
    http://sqlsaga.com/sql-server/how-to-concatenate-rows-into-one-row-using-stuff/
    DECLARE @Input TABLE
    ReqNbr INT,
    ServiceCall VARCHAR(20)
    INSERT INTO @Input VALUES(1, '0001'), (1, '0002'), (1, '0003'),(2,'0004'), (2,'0005'), (1, '0006')
    SELECT DISTINCT ReqNbr, STUFF((SELECT ';'+ServiceCall FROM @Input b WHERE a.ReqNbr = b.ReqNbr FOR XML PATH('')), 1, 1, '') AS ServiceCall
    FROM @Input a
    Please mark as answer, if this has helped you solve the issue.
    Good Luck :) .. visit www.sqlsaga.com for more t-sql code snippets and BI related how to articles.

  • Problem to run the Crystal report inside from SAP B1 based on SQL views.

    Hello,
    I have a problem to run my Crystal report inside from SAP B1 which is based on SQL views.And the SQL views are stored in a separate database in SQL server.The error which i am getting is saying the the tablename does not exist.What i need to do in order to sort this problem.
    Great if somebody can help me to sort out this so that i can run my report based on SQL views stored on separate database other than SAP databases inside from SAP B1.
    Edited by: rozenagrawal on Apr 19, 2011 11:51 AM

    Try using a SQL synonym in your company database for the views outside the company database. I don't know if SBO will let you get away with it, but its worth a shot.
    If your company database is MyCompany and you have a view called MyView in Views database, assuming the view belongs to schema dbo, and you want the synonym to belong to dbo schema in your company database, run this:
    Use MyCompany
    go
    create synonym dbo.OutsiderView for
    Views.dbo.MyView
    go
    select * from OutsiderView
    The select statement should return the contents of MyView in the Views database while you are connected to your MyCompany database.
    For more info, see the Books Online for MSSQL on topic synonym.
    You will need to change your CR options to include displaying synonyms along with tables, views, etc. You may also need to grant select to B1 users.
    Edited by: Cindy Lange on Apr 21, 2011 4:00 PM

  • Java swing tree view interact with indesign javascript

    i have java swing tree view(program).if i execute my program it will all indesign script folder files in tree view. what is my problem is if i click the script
    i want to execute. is it possible to execute indesign javascrpt from java swing UI. could anyone tell me pls.

    Sorry if I did not make this clear:
    This is not an InDesign issue but a Java issue. Search, or ask in a Java forum for best practice to deal with the mentioned platform specific mechanisms:
    - inter process communication (AppleEvent or TLB/OLE )
    - command line / shell script invokation
    - a way to launch an JSX script - the equivalent mechanism to File.execute() in Extendscript.
    For example, if I ask Google for "Java TLB", the second hit takes me to:
    http://dev.eclipse.org/newslists/news.eclipse.tools/msg09883.html
    Eventually you can reuse the DLL and jar - I haven't read that far.
    Google for Java AppleEvent:
    http://developer.apple.com/samplecode/AppleEvent_Send_and_Receive/listing2.html
    Note the 1999 copyright, this is pre-OSX. Also located in a "legacy documents" area. Apple has the bad habit to deprecate/abandon most of their technology every other year, so I would not be surprised if it does not work any more and you'd have to write you own JNI, JDirect or JNIDirect glue ( I don't even know the current buzzword). Ah, further digging unveiled that they even dropped the successor which was named "CocoaJava".
    If Mac specific, maybe post your questions to this list: http://lists.apple.com/mailman/listinfo/java-dev
    Dirk

  • SQL Views for applications, deployment types and deployments

    Has anyone seen any diagrams yet of the relationship between the views in the database for applications?  They are needless to say quite a bit more complex than the old Packages/Programs/Advertisements views.  I can probably figure out what I need,
    but it would save quite a time to be able to see the relationships called out.  A description of what some of the views actually do would be helpful too, I can figure out some, but others are a bit obtuse.
    Unfortunately there isn't an out of the box report that shows the information my customer wants, so I have to create one from scratch.
    If anyone is currious they want to see the status for all the computers that are targetted with an application deployment, this would include error codes, status, ect...
    Bob

    Yes, I know this is an old post, but I’m trying to clean them up. Did you solve this problem, if so what was the solution?
    The SQL view document has been release, it should help you out.
    https://technet.microsoft.com/en-us/library/dn581978.aspx
    Garth Jones | My blogs: Enhansoft and
    Old Blog site | Twitter:
    @GarthMJ

  • Study: Oracle database software has more flaws than SQL Server

    Hi,
    Study: Oracle database software has more flaws than SQL Server
    Microsoft is often unfairly slammed for security issues, says NGSS
    http://www.computerworld.com/action/article.do?command=viewArticleBasic&articleId=9005383&intsrc=hm_list
    Post your comments on this stupid artical.
    Thanks!
    M T

    This is a case where size does matter.
    When they say errors reported on oracle are about 4 times more than the ones reported on SQL server they forgot to say something like: SQL server is able to do... what a 10%, a 5% or whatever of what oracle can do.
    Anyway who sayd this forgot to say that they worked with microsoft trying to improve SQL sever security features as well.
    http://www.nextgenss.com/press-releases/ngs-and-the-sql-server-security-essential-guide/
    They have a reason to say it. Who would say "I made a bad job!"
    In my opinion there is no way yet to compare oracle to any other DBMS under any point of view.
    Bye Alessandro

  • View Resource Requirments with 11.5.8

    Discrete Mfg using 11.5.8
    Question on the View Discrete Resources form. WIP>>>JOB/SCHEDULE DETAILS>>>VIEW RESOURCE REQUIREMENTS
    How does a job "qualify" for showing up on this form?
    When does a job "Come off" this form?
    I have jobs of all types of statuses that still show whether the job is Unreleased, Released, Cancelled or Closed.

    Thanks...so that means basically the information behind this form could possibly show all jobs in your database and that is why one would utilize the status or dates as a control right? I guess I was hoping that it was more along the lines of real time information with what is at the resource. We are looking at a way without coming up with another custom report that would give us a dispatch list sort by resource. Most standard reports appear to be department driven.

  • Use evdre to query data from a SQL View

    Hi all
    I believe that it is possible to use evdre to query data from a SQL View. If this is possible then how does one go about setting it up in the evdre options (assuming that the view has already been created)?
    Regards,
    Byron

    Byron,  perhaps this is no longer supported, it might be worth opening up a case at service.sap.com on this.  However, I did find the following on Page 11 of the "Usages and Considerations of EVDRE" pdf file.  This doc is imbedded in the helpfile for BPC 7 SP5 (which was released in August of 2009, well after note 1315011 was last updated.
    It looks like you are limited to one custom view per application, since you have to name the view in a parameter at the APPLICATION level.  Go into BPC Administration, login to the application related to the custom view, choose "Set Application Parameters" and enter the name of the view to the Application Parameter called "EVDRE_QUERYVIEWNAME"  If it is not listed, go ahead and create it at the bottom of the Application parameter screen.
    Also:  I interpreted the following info from Page 10 of the same doc:
    In your EVDRE, set the following options:
    QueryEngine: MANUAL
    QueryType:  enter either NEXJ  OR TUPLE  see below:
    NEXJ  - Use two-dimensional queries using the nonemptycrossjoin function
    TUPLE  - Use two-dimensional queries using tuples"
    And I'm assuming you'd enter a Y for the following two parameters:
    QueryViewName
    "..to enforce the query engine to use a used-defined SQL view of the fact tables, when trying to read the values using SQL queries. This option is typically used in conjunction with the SQLOnly option (see below). "
    Option SQLOnly
    "..to enforce the query engine to only execute SQL queries, when reading data. This can be achieved using this option."

  • Problem in JAVA PL/SQL Block

    Hi all,
    I am facing a peculiar problem. I have one JAVA PL/SQL code, which runs a shell script, which indeed fire a zipping command remotely. Here I am providing you the code. Actually it zip some files at application server running from Database Server.
    create or replace procedure RC(p_cmd in varchar2)
    as
    x number;
    begin
    x := run_cmd(p_cmd);
    EXCEPTION
    when others then
    dbms_output.put_line('WHEN OTHERS '||sqlcode||sqlerrm);
    end;
    <====This RC is called from a before insert trigger. And value of p_cmd is $ORACLE_BASE/report_compress.sh $REPORT_DIR/<report_file>.
    create or replace
    function RUN_CMD(p_cmd in varchar2) return number
    as
    language java
    name 'Util.RunThis(java.lang.String) return integer';
    create or replace and compile
    java source named "Util"
    as
    import java.io.*;
    import java.lang.*;
    public class Util extends Object
    public static int RunThis(String args)
    Runtime rt = Runtime.getRuntime();
    int rc = -1;
    try
    Process p = rt.exec(args);
    int bufSize = 4096;
    BufferedInputStream bis =
    new BufferedInputStream(p.getInputStream(), bufSize);
    int len;
    byte buffer[] = new byte[bufSize];
    // Echo back what the program spit out
    while ((len = bis.read(buffer, 0, bufSize)) != -1)
    System.out.write(buffer, 0, len);
    rc = p.waitFor();
    catch (Exception e)
    e.printStackTrace();
    rc = -1;
    finally
    return rc;
    And also I have executed:
    BEGIN
    dbms_java.grant_permission('<DB_USER>','java.io.FilePermission','$ORACLE_BASE','write');
    dbms_java.grant_permission('<DB_USER>','java.io.FilePermission','$ORACLE_BASE/report_compress.sh','execute');
    dbms_java.grant_permission('<DB_USER>','java.lang.RuntimePermission','*', 'writeFileDescriptor' );
    END;
    REPORT_COMPRESS.SH
    #!/bin/sh
    remsh <APPLICATION SERVER IP> -l <APPLICATION_SERVER_OS_USER> -n "gzip -f $1"
    Now problem is while execute RC, it gives no error but the remote file does not get zipped. When I run report_compress.sh from command promt, it works fine.
    Earlier we used HP-UX as our DB server and Application Server. And RC worked fine there. Recently we have moved to AIX(for both DB and AS), and now we are facing this problem.
    Please guide me to resolve this problem.
    Note: .rhosts entry is fine in both the servers(as per me) as report_compress.sh is working fine.

    Make sure that the .profile does not read something from tty - it should not, but it sounds like the .profile is expecting tty input.
    Alternatively, simply copy and paste the environment settings from .profile to your compress script. The only read important setting is PATH as your script simply does a remote shell. Thus LD_LIBRARY_PATH/SHLIB_PATH and other settings are not needed.
    You can also add debugging to your shell script - useful when executing it in the background.
    Something as follows:
    # create debug file name
    DEBUGFILE=/tmp/~$$.debug-out # e.g. /tmp/~1234.debug-out where 1234 is the PID
    echo "`date` Starting [$0] with parameters [$*]" >> $DEBUGFILE
    # sourcing environment
    echo "Loading default profile..." >>$DEBUGFILE
    . /home/oracle/.profile 1>>$DEBUGFILE 2>>$DEBUGFILE
    # running remote shell
    echo "Running remote shell..." >>$DEBUGFILE
    remsh ... 1>>$DEBUGFILE 2>>$DEBUGFILE
    .. etc.
    When this is working, you can remove the debug file from the shell script, or simply delete it when the script is successful.

  • Report Based on SQL view not pulling in all parameters

    Post Author: ronhawker
    CA Forum: .NET
    I based a report on a SQL view below:SELECT     TOP (100) PERCENT CorpDirectory.Position, CorpDirectory.PhoneDirect, CorpDirectory.Email, CorpDirectory.Store, CorpDirectory.Name,                       CorpDirectory.PhoneFaxWave, CorpDirectory.Department, Store.StoreName, Store.StoreStreetAddress, Store.StoreCity, Store.StoreState,                       Store.StoreZip, Store.StorePhone, CorpDirectory.DisplayOrderFROM         dbo.CorpDirectory AS CorpDirectory INNER JOIN                      dbo.Store AS Store ON CorpDirectory.Store = Store.StoreORDER BY CorpDirectory.Store, CorpDirectory.Department, CorpDirectory.DisplayOrder, CorpDirectory.Name When the report was created the order by sequence only brought in the first parameter of CorpDirectory.Store. It seemed to ignore the other three order by parameters. I am running 10.2 is VS2005.

    Sharmila,
    Thanks for your response. Maybe I wasn't clear enough in my previous statement. I will give an example of what I am trying to accomplish.
    Let's say I have 2 date fields(SUBMITDATE,COMPLETEDATE) in a table TABLE A
    I want to calculate a field called CYCLETIME with the following conditions:
    If COMPLTEDATE is NULL, then CYCLETIME = SYSDATE-SUBMITDATE
    IF COMPLTEEDATE is not null, then CYCLETIME = COMPLTEEDATE-SUBMITDATE
    Would appreciate any help.
    Thanks
    Dev
    Hi,
    You can do the calculation in the sql query itself. Here is an example which shows the sum of salaray for each department in the scott.emp table.
    select deptno,sum(sal) sal
    from scott.emp
    group by deptno
    Thanks,
    Sharmila

  • Can a SQL view see data from an ODBC connection?

    Hi.  I currently have an application that pulls data from a custom SQL view in my SQL database.  This custom application can not be changed, so it expects to see the data exactly as presented by my custom SQL view.  This works fine
    when the data resides in SQL, but I am not sure if it is possible when the data resides outside of SQL.  I’d like to connect to another type of database via an ODBC connection from my SQL database, and still utilize my custom SQL view.  I would prefer to NOT
    use the SQL database as a warehouse, and simply use it to pass data.
    Is this possible?   Thank you for reading.

    Hi Robet,
    According to your description, you want to create view in SQL Server to pass data from OBDC database to custom application, right?
    In this case, we can create linked server to access an ODBC database when you are using an ODBC data source. Linked servers can use the OLE DB Provider for ODBC without using an ODBC data source. You can refer to the link below to see the details.
    http://technet.microsoft.com/en-us/library/ms191462(v=sql.105).aspx
    Regards,
    Charlie Liao
    TechNet Community Support

  • Declare @StartDate/@EndDate in SQL View; cannot save (for use w/ ODBC)

    I have searched all over to find out how, in proper syntax, to code a date range-specific query that works just fine in SAP, but cannot be saved in a SQL view (to in turn be linked to an Excel spreadsheet).  An answer that links me to the proper thread could be nice... if it truly explains how to begin and end a functioning basic query with a user supplied date range while working in Excel.
    The error I receive when starting my view with "declare" is "the Declare cursor SQL construct or statement is not supported."
    Here's the beginning and abbreviated end of code from a query that works just fine without the date clause in SQL view:
    DECLARE @StartDate DateTime
    DECLARE @EndDate DateTime
    SET              @StartDate = [%0]
    SET              @EndDate = [%1]
    SELECT     .........
    FROM        .........
    WHERE     (T0.DocDueDate >= @StartDate AND T0.DocDueDate <= @EndDate) AND ......
    Thank you in advance!
    Russell

    Hi Russell.
    You don't need to use Declare.
    Try this
    SELECT .........
    FROM .........
    WHERE (T0.DocDueDate >= '[[%0]]' AND T0.DocDueDate <= '[[%1]]') AND ......
    Antonio Ramos
    Edited by: Antonio Ramos on Feb 17, 2010 2:38 PM

Maybe you are looking for

  • Cannot install Adobe AIR 2.0 on Windows 7 64.

    Each time I run the Adobe Installer I get the same error. An error occured while Installing Adobe AIR. Installation may not be allowed by your administrator. Please contact your administrator. I am the administrator and I uninstalled the older versio

  • Delivery free of charge

    Hi all, When I am doing FD,the price is picking in the sales order and its not zero. The Doc pricing procedure is C in VOV8 and in pricing procedure determination.Still its picking the price from condition records. Kindly help..

  • CTI OS can't transfer call

    Hi i am facing an issue with ctios agent desktop. If agent try to blind transfer or consultative transfer or make a conference call system displays some resources error like "Resources are not available" while if we try to make all these scenarios th

  • File location of Spotlight found items

    Hi, in prior versions of OS X, Spotlight had a feature in which if I positioned the mouse pointer one of the items in the list of found items, a "tool tip" would appear, showing the full file path.  This was useful if I was cleaning out my system and

  • Kerberos Ticket via Java to BW to access BW Querys with HTTP POST

    Hi and thanks for reading, im Working with 2004 and the NWDS SP10. We have a project which must show some reports from the HR system via backend and some BW Reports done with Web Application Designer 3.5. The user of the project application is able t