Problems While Extracting Hours From Date Field

Hi Guys,
Hope you are doing well.
I am facing some problems while extracting hours from date field. Below is an example of my orders table:-
select * from orders;
Order_NO     Arrival Time               Product Name
1          20-NOV-10 10:10:00 AM          Desktop
2          21-NOV-10 17:26:34 PM          Laptop
3          22-JAN-11 08:10:00 AM          Printer
Earlier there was a requirement that daily how many orders are taking place in the order's table, In that I used to write a query
arrival_time>=trunc((sysdate-1),'DD')
and arrival_time<trunc((sysdate),'DD')
The above query gives me yesterday how many orders have been taken place.
Now I have new requirement to generate a report on every 4 hours how many orders will take place. For an example if current time is 8.00 AM IST then the query should fetch from 4.00 AM till 8 AM how many orders taken place. The report will run next at 12.00 PM IST which will give me order took place from 8.00 AM till 12.00 PM.
The report will run at every 4 hours a day and generate report of orders taken place of last 4 hours. I have a scheduler which will run this query every hours, but how to make the query understand to fetch order details which arrived last 4 hours. I am not able to achieve this using trunc.
Can you please assist me how to make this happen. I have checked "Extract" also but I am not satisfied.
Please help.
Thanks In Advance
Arijit

you may try something like
with testdata as (
  select sysdate - level/24 t from dual
  connect by level <11
select
  to_char(sysdate, 'DD-MM-YYYY HH24:MI:SS') s
, to_char(t, 'DD-MM-YYYY HH24:MI:SS') t from testdata
where
t >= trunc(sysdate, 'HH') - numtodsinterval(4, 'HOUR')
S     T
19-06-2012 16:08:21     19-06-2012 15:08:21
19-06-2012 16:08:21     19-06-2012 14:08:21
19-06-2012 16:08:21     19-06-2012 13:08:21
19-06-2012 16:08:21     19-06-2012 12:08:21trunc ( ,'HH') truncates the minutes and seconds from the date.
Extract hour works only on timestamps
regards
Edited by: chris227 on 19.06.2012 14:13

Similar Messages

  • APEX - SQL Workshop - SQL Commands : Issue in extracting hour from date

    Hello All,
    When I run
    SELECT to_char(sysdate,'hh24') from DUALon SQL Developer and APEX SQL Commands window, both are returning correct hour value.
    But when I run
    SELECT to_char(i_date,'hh24') from t_factthen I'm getting correct values in SQL Developer but not in APEX SQL Commands window. In APEX, it always returns '00' for all rows. I'm totally lost what could be the issue with APEX? Any suggestions?
    DB Version: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    APEX Version: 4.0.1.00.03
    Web Server : EPG
    Table structure:
    CREATE TABLE  "T_FACT"
       (     "TF_KEY" NUMBER,
         "TOWER" VARCHAR2(20),
         "LOC_ID" NUMBER,
         "TF_CAT" VARCHAR2(35),
         "EQP_NAME" VARCHAR2(35),
         "I_DATE" DATE,
         "MON_CATEGORY" VARCHAR2(35),
         "EVENT" VARCHAR2(35),
         "UNIT" VARCHAR2(35),
         "TF_VALUE" NUMBER
       );Regards,
    Hari

    Hi,
    Just silly question case you have same table in multiple schemas:
    You run query in same schema?
    Regards,
    Jari

  • Hi this message appears after 2 hours downloading Mavericks : an error occurred while extracting files from the package "mzps4135638417199433253.pkg"

    Hi this message appears after 2 hours downloading Mavericks in App Store :
    an error occurred while extracting files from the package "mzps4135638417199433253.pkg"
    Same with "CMD + R"
    Help...

    It sounds to me like your Internal Hard Drive is failing.
    I recommend you buy a new one, that is a good candidate for replacing the old one, but install it in an External enclosure and Install a fresh Mac OS X on it from the DVD. You can boot your Mac from any attached drive.
    The new System can be used to get some work done, check your emails, and takes the pressure off resolving this immediately. You can also attempt to salvage files off the old drive if needed.
    Once things seem to be working, then move the new drive inside the computer. Failures at this point may be due to bad cable, which has been a problem in some of these MacBooks.
    Use security erase, write Zeroes, one pass, to re-write every block on the old drive. Any block discovered to be bad will be replaced with spares the drive holds in reserve for this purpose. If more than 10 blocks are pared on one pass, "Initialization Failed!" will be the result. Although you can try the erase again, there is some question whether you want to trust this drive with your precious data.

  • Problem while selecting BELNR from BSEG

    Hi Experts,
    I have a report performance problem while fetching BELNR from BSEG table.
    I have to print latest BELNR from BSEG where BUZID = ‘M’ but at the time of execution of report, It is taking too much time (More that hour and sometimes it gets hanged).
    I have also gone through the comments provided by experts for previous problems asked in this forum e.g. BSEG is a cluster table that is why data retrieval takes long time etc.
    Can any one has any other idea or suggestion  or any other way to solve this problem
    Regards,
    Neeraj

    Hi,
    1) Try to create an index on BUZID field
    2) Don't use SELECT/ENDSELECT statement. Instead of that extract all the concerned entries from BSEG into an internal table :
    select belnr from bseg appending table itab where buzid = 'M'.
    then do this :
    sort itab by belnr.
    describe itab lines n.
    read table itab index n.
    Please reward if helpful.
    Regards,
    Nicolas.

  • "An error occurred while extracting files from the package "BaseSystem.pkg".

    Hello!
    I have a
    MacBookPro5,5
    Prozessortyp:Intel Core 2 Duo
    Prozessorgeschwindigkeit:2.26 GHz
    Anzahl der Prozessoren:1
    Gesamtzahl der Kerne:2
    L2-Cache:3 MB
    Speicher:2 GB
    Busgeschwindigkeit:1.07 GHz
    Boot-ROM-Version:MBP55.00AC.B03
    SMC-Version (System):1.47f2
    Hardware-UUID:A2DD27C4-9829-5A4D-854B-485EF8A6B20F
    Problem:
    I upgraded Leopard to Snow Leopard. Everything worked fine for a month. To free up disk space I deleted some of the iPhoto flders (modfied and original images). Everything worked still fine. Shut down the computer. Next day it was incredibly slow. At the same time the indexing was running. I stopped indexing, but stll slow. Every operation took minutes. I tried all the tricks that I found in the internet (repaired file permissions, repaired disk, cleared PRAM , moved big filed from desktop, etc.). After 24 full hours of trying all this I decided to erase the hard drive and reinstall, directly from the Snow Leopard Install disk, but it fails after downloading the packages. Below is the part of the log. Then I tried to use the old Leopard install DVD to reinstall Leopard, it then sais estimated time 12 hours or so and eventually crashed, spitting out a lot of "reportcrash" in the log. What is going on? I'm running out of options. Any advice? Would zeroing the hard drive help? If nothing else I plan to buy a new hard drive, since the only explanation I have is that there is a problem with the hard driven although the disk utility says it is OK. I need a bigger one anyway. Any ideas? Thank you!
    Aug 16 05:17:31 localhost OSInstaller[139]: IFPKInstallElement (191 packages)
    Aug 16 05:17:35 localhost OSInstaller[139]: PackageKit: ----- Begin install -----
    Aug 16 05:17:35 localhost OSInstaller[139]: PackageKit: request=PKInstallRequest <191 packages, destination=/Volumes/Macintosh HD>
    Aug 16 05:17:36 localhost OSInstaller[139]: PackageKit: Extracting /Volumes/Macintosh HD/Mac OS X Install Data/BaseSystem.pkg (destination=/Volumes/Macintosh HD/.OSInstallSandbox-tmp/Root, uid=0)
    Aug 16 05:31:59 localhost Unknown[80]: /SourceCache/AppleFSCompression/AppleFSCompression-24.0.1/Common/DataPool.c:116 : Error: finished pool without filling it
    Aug 16 05:31:59 localhost Unknown[80]: /SourceCache/AppleFSCompression/AppleFSCompression-24.0.1/Common/commonUtils.c: 315: Error: fh_pread -1
    Aug 16 05:31:59 localhost Unknown[80]: /SourceCache/AppleFSCompression/AppleFSCompression-24.0.1/Common/StreamCompress or.c:236: Error: write failed for /Volumes/Macintosh HD/.OSInstallSandbox-tmp/Root//System/Library/Frameworks/OpenCL.framework/Versi ons/A/Resources/runtime.amdil.bc: Invalid argument
    Aug 16 05:31:59 localhost Unknown[80]: /SourceCache/AppleFSCompression/AppleFSCompression-24.0.1/Common/StreamCompress or.c:260: Error: futimes failed for /Volumes/Macintosh HD/.OSInstallSandbox-tmp/Root//System/Library/Frameworks/OpenCL.framework/Versi ons/A/Resources/runtime.amdil.bc: Invalid argument
    Aug 16 05:31:59 localhost Unknown[80]: /SourceCache/AppleFSCompression/AppleFSCompression-24.0.1/Common/StreamCompress or.c:829: Error: returning errno 22 from FinishStreamCompressorQueue
    Aug 16 05:32:10 localhost OSInstaller[139]: PackageKit: Install Failed: PKG: extracting "com.apple.pkg.BaseSystem"\nError Domain=PKInstallErrorDomain Code=110 UserInfo=0x12c8366a0 "An error occurred while extracting files from the package “BaseSystem.pkg”." Underlying Error=(Error Domain=BOMCopierFatalError Code=22 UserInfo=0x12e703300 "The operation couldn’t be completed. FinishStreamCompressorQueue error") {\n    NSFilePath = "/Volumes/Macintosh HD/.OSInstallSandbox-tmp/Root";\n    NSLocalizedDescription = "An error occurred while extracting files from the package \U201cBaseSystem.pkg\U201d.";\n    NSURL = "BaseSystem.pkg -- file://localhost/Volumes/Macintosh%20HD/Mac%20OS%20X%20Install%20Data/index.pro duct";\n    NSUnderlyingError = "Error Domain=BOMCopierFatalError Code=22 UserInfo=0x12e703300 \"The operation couldn\U2019t be completed. FinishStreamCompressorQueue error\"";\n    PKInstallPackageIdentifier = "com.apple.pkg.BaseSystem";\n}
    Aug 16 05:32:10 localhost OSInstaller[139]: install:didFailWithError:Error Domain=PKInstallErrorDomain Code=110 UserInfo=0x12c8366a0 "An error occurred while extracting files from the package “BaseSystem.pkg”." Underlying Error=(Error Domain=BOMCopierFatalError Code=22 UserInfo=0x12e703300 "The operation couldn’t be completed. FinishStreamCompressorQueue error")
    Aug 16 05:32:11 localhost OSInstaller[139]: Install failed: Die Installation ist aufgrund eines Fehlers fehlgeschlagen. Wenden Sie sich an den Hersteller der Software.
    Aug 16 05:32:13 localhost OSInstaller[139]: Allowing machine sleep.
    Aug 16 05:32:15 localhost OSInstaller[139]: Memory statistics for 'Installation ist fehlgeschlagen' pane:
    Aug 16 05:32:15 localhost OSInstaller[139]: Physical Memory Allocation:   139 MB wired,   259 MB trapped,   397 MB active,     7 MB inactive,  1246 MB free,  1650 MB usable,  2048 MB total

    It sounds to me like your Internal Hard Drive is failing.
    I recommend you buy a new one, that is a good candidate for replacing the old one, but install it in an External enclosure and Install a fresh Mac OS X on it from the DVD. You can boot your Mac from any attached drive.
    The new System can be used to get some work done, check your emails, and takes the pressure off resolving this immediately. You can also attempt to salvage files off the old drive if needed.
    Once things seem to be working, then move the new drive inside the computer. Failures at this point may be due to bad cable, which has been a problem in some of these MacBooks.
    Use security erase, write Zeroes, one pass, to re-write every block on the old drive. Any block discovered to be bad will be replaced with spares the drive holds in reserve for this purpose. If more than 10 blocks are pared on one pass, "Initialization Failed!" will be the result. Although you can try the erase again, there is some question whether you want to trust this drive with your precious data.

  • Business partner change Valid From Date field

    How can I change the Valid From Date field in tables:
    BUT000
    BUT020
    BUT0BK
    BUT100
    Currently the of date of creation of the business partner is in this tables' Valid From field.
    In transaction BP the Address of the Business Partner is  valid from 01.01.1990 but still I get a warning that the business partner is not valid for date 01.11.2011.

    Sounds like the problem is the valid to date.  What is that date set to?

  • I am facing problem while reading values from properties file ...i am getting null pointer exception earlier i was using jdeveloper10g now i am using 11g

    i am facing problem while reading values from properties file ...i am getting null pointer exception earlier i was using jdeveloper10g now i am using 11g

    hi TimoHahn,
    i am getting following exception in JDeveloper(11g release 2) Studio Edition Version 11.1.2.4.0 but it works perfectly fine in JDeveloper 10.1.2.1.0
    Root cause of ServletException.
    java.lang.NullPointerException
    at java.util.PropertyResourceBundle.handleGetObject(PropertyResourceBundle.java:136)
    at java.util.ResourceBundle.getObject(ResourceBundle.java:368)
    at java.util.ResourceBundle.getString(ResourceBundle.java:334)
    at org.rbi.cefa.master.actionclass.UserAction.execute(UserAction.java:163)
    at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
    at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
    at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
    at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)
    at java.security.AccessController.doPrivileged(Native Method)
    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)
    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:442)
    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)
    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)
    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:139)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

  • Problem while accessing a complex data type

    hi,
    I am getting a problem while accessing a complex data type
    I have a wsdl as:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <definitions name="OutlookReminderService" targetNamespace="http://ws.aftek.com/outlook-reminder" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:ns2="http://ws.aftek.com/outlook-reminder/schemas" xmlns:ns3="http://java.sun.com/jax-rpc-ri/internal" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://ws.aftek.com/outlook-reminder" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    - <types>
    - <schema targetNamespace="http://ws.aftek.com/outlook-reminder/schemas" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://ws.aftek.com/outlook-reminder/schemas" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
    <import namespace="http://java.sun.com/jax-rpc-ri/internal" />
    - <complexType name="TaskVO">
    - <sequence>
    <element name="dueDate" type="long" />
    <element name="percentageComplete" type="int" />
    <element name="priorty" type="int" />
    <element name="reminderDate" type="long" />
    <element name="reminderSet" type="boolean" />
    <element name="startDate" type="long" />
    <element name="status" type="int" />
    <element name="subject" type="string" />
    <element name="taskId" type="string" />
    </sequence>
    </complexType>
    - <complexType name="NoSuchUserException">
    - <sequence>
    <element name="message" type="string" />
    </sequence>
    </complexType>
    - <complexType name="ArrayOfContactVO">
    - <complexContent>
    - <restriction base="soap11-enc:Array">
    <attribute ref="soap11-enc:arrayType" wsdl:arrayType="tns:ContactVO[]" />
    </restriction>
    </complexContent>
    </complexType>
    - <complexType name="ContactVO">
    - <sequence>
    <element name="birthDate" type="long" />
    <element name="companyAddress" type="string" />
    <element name="companyName" type="string" />
    <element name="emailID1" type="string" />
    <element name="emailID2" type="string" />
    <element name="emailID3" type="string" />
    <element name="faxNumber" type="string" />
    <element name="firstName" type="string" />
    <element name="homeAddress" type="string" />
    <element name="lastName" type="string" />
    <element name="middleName" type="string" />
    <element name="mobileNumber" type="string" />
    <element name="phoneNumber" type="string" />
    <element name="workContactNumber" type="string" />
    </sequence>
    </complexType>
    </schema>
    - <schema targetNamespace="http://java.sun.com/jax-rpc-ri/internal" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://java.sun.com/jax-rpc-ri/internal" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
    <import namespace="http://ws.aftek.com/outlook-reminder/schemas" />
    - <complexType name="arrayList">
    - <complexContent>
    - <extension base="tns:list">
    <sequence />
    </extension>
    </complexContent>
    </complexType>
    - <complexType name="list">
    - <complexContent>
    - <extension base="tns:collection">
    <sequence />
    </extension>
    </complexContent>
    </complexType>
    - <complexType name="collection">
    - <complexContent>
    - <restriction base="soap11-enc:Array">
    <attribute ref="soap11-enc:arrayType" wsdl:arrayType="anyType[]" />
    </restriction>
    </complexContent>
    </complexType>
    </schema>
    </types>
    <message name="OutlookServer_addTaskResponse" />
    - <message name="OutlookServer_getListResponse">
    <part name="result" type="ns3:arrayList" />
    </message>
    - <message name="OutlookServer_getContactListResponse">
    <part name="result" type="ns2:ArrayOfContactVO" />
    </message>
    - <message name="NoSuchUserException">
    <part name="NoSuchUserException" type="ns2:NoSuchUserException" />
    </message>
    - <message name="OutlookServer_getContactList">
    <part name="String_1" type="xsd:string" />
    </message>
    - <message name="OutlookServer_getList">
    <part name="String_1" type="xsd:string" />
    </message>
    - <message name="OutlookServer_addTask">
    <part name="String_1" type="xsd:string" />
    <part name="TaskVO_2" type="ns2:TaskVO" />
    </message>
    - <message name="OutlookServer_reminderOccurredResponse">
    <part name="result" type="xsd:boolean" />
    </message>
    - <message name="OutlookServer_reminderOccurred">
    <part name="String_1" type="xsd:string" />
    <part name="TaskVO_2" type="ns2:TaskVO" />
    </message>
    - <portType name="OutlookServer">
    - <operation name="addTask" parameterOrder="String_1 TaskVO_2">
    <input message="tns:OutlookServer_addTask" />
    <output message="tns:OutlookServer_addTaskResponse" />
    <fault message="tns:NoSuchUserException" name="NoSuchUserException" />
    </operation>
    - <operation name="getContactList" parameterOrder="String_1">
    <input message="tns:OutlookServer_getContactList" />
    <output message="tns:OutlookServer_getContactListResponse" />
    <fault message="tns:NoSuchUserException" name="NoSuchUserException" />
    </operation>
    - <operation name="getList" parameterOrder="String_1">
    <input message="tns:OutlookServer_getList" />
    <output message="tns:OutlookServer_getListResponse" />
    <fault message="tns:NoSuchUserException" name="NoSuchUserException" />
    </operation>
    - <operation name="reminderOccurred" parameterOrder="String_1 TaskVO_2">
    <input message="tns:OutlookServer_reminderOccurred" />
    <output message="tns:OutlookServer_reminderOccurredResponse" />
    <fault message="tns:NoSuchUserException" name="NoSuchUserException" />
    </operation>
    </portType>
    - <binding name="OutlookServerBinding" type="tns:OutlookServer">
    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
    - <operation name="addTask">
    <soap:operation soapAction="" />
    - <input>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </input>
    - <output>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </output>
    - <fault name="NoSuchUserException">
    <soap:fault encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" name="NoSuchUserException" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </fault>
    </operation>
    - <operation name="getContactList">
    <soap:operation soapAction="" />
    - <input>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </input>
    - <output>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </output>
    - <fault name="NoSuchUserException">
    <soap:fault encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" name="NoSuchUserException" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </fault>
    </operation>
    - <operation name="getList">
    <soap:operation soapAction="" />
    - <input>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </input>
    - <output>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </output>
    - <fault name="NoSuchUserException">
    <soap:fault encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" name="NoSuchUserException" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </fault>
    </operation>
    - <operation name="reminderOccurred">
    <soap:operation soapAction="" />
    - <input>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </input>
    - <output>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </output>
    - <fault name="NoSuchUserException">
    <soap:fault encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" name="NoSuchUserException" namespace="http://ws.aftek.com/outlook-reminder" use="encoded" />
    </fault>
    </operation>
    </binding>
    - <service name="OutlookReminderService">
    - <port binding="tns:OutlookServerBinding" name="OutlookServerPort">
    <soap:address location="http://truptid:8080/outlook-reminder-service/outlook" />
    </port>
    </service>
    </definitions>
    My client is :
    private static String     BODY_NAMESPACE_VALUE     = "http://ws.abc.com/outlook-reminder";
         private static String     ENCODING_STYLE_PROPERTY     = "javax.xml.rpc.encodingstyle.namespace.uri";
         private static String     NS_XSD                         = "http://www.w3.org/2001/XMLSchema";
         private static String     URI_ENCODING               = "http://schemas.xmlsoap.org/soap/encoding/";     
    try{
    ServiceFactory factory = ServiceFactory.newInstance();
                        Service service = factory.createService(new QName("OutlookReminderService"));
                        QName port =new QName("OutlookReminderService","OutlookServerPort");
                        Call call =service.createCall(port);
                        call.setTargetEndpointAddress("http://localhost:8080/outlook-reminder-service/outlook?wsdl");
                        call.setProperty(Call.SOAPACTION_USE_PROPERTY, new Boolean(true));
                        call.setProperty(Call.SOAPACTION_URI_PROPERTY, "");
                        call.setProperty(ENCODING_STYLE_PROPERTY, URI_ENCODING);
                        call.getReturnType();
                        call.setOperationName(new QName(BODY_NAMESPACE_VALUE, "getList"));
                        QName QNAME_TYPE_STRING = new QName(NS_XSD, "string");
                        call.addParameter("String_1", QNAME_TYPE_STRING, ParameterMode.IN);
                        //http://ws.aftek.com/outlook-reminder/schemas
                        QName QNAME_TYPE_VO = new QName("http://schemas.xmlsoap.org/soap/encoding/", "Array");
                        System.out.println("Before Add Parameter");
                   //     call.addParameter("result", QNAME_TYPE_VO, ParameterMode.OUT);
                        call.setReturnType(QNAME_TYPE_VO,ArrayList.class);
                        System.out.println("After Add Parameter");
                        Object[] params ={oUserVO.getUserName()};
                        oArrayList =(ArrayList)call.invoke(params);
                        System.out.println("After Invoked");
                        //System.out.println("invoked"+ arrayList);          
                   catch(SOAPFaultException faultException)
                        moLogger.debug("SOAPFaultException : ", faultException);
                   catch(RemoteException oremoteException)
                        moLogger.debug("RemoteException", oremoteException);
              catch(ServiceException oServiceException)
                        moLogger.debug("ServiceException", oServiceException);          }          
    Error got is :
    trailing block elements must have an id attribute
         at com.sun.xml.rpc.encoding.SOAPDeserializationContext.deserializeMultiRefObjects(SOAPDeserializationContext.java:81)
         at com.sun.xml.rpc.client.StreamingSender._send(StreamingSender.java:239)
         at com.sun.xml.rpc.client.dii.CallInvokerImpl.doInvoke(CallInvokerImpl.java:103)
         at com.sun.xml.rpc.client.dii.BasicCall.invoke(BasicCall.java:492)
         at com.ail.dhg.poc.business.dao.ContactDAO.getList(ContactDAO.java:255)
         at com.ail.dhg.poc.business.facade.ContactFacade.getList(ContactFacade.java:189)
         at com.ail.dhg.poc.business.AcceptInput.main(AcceptInput.java:72)
    java.lang.NullPointerException
         at com.ail.dhg.poc.business.dao.ContactDAO.getList(ContactDAO.java:277)
         at com.ail.dhg.poc.business.facade.ContactFacade.getList(ContactFacade.java:189)
         at com.ail.dhg.poc.business.AcceptInput.main(AcceptInput.java:72)
    Message was edited by:
    trupti_d

    Use lower case letters for your variable names (name, pwd). The code works then.
    package com.bluenile.bean;
    import java.io.*;
    public class Bean1 implements Serializable
    private String name="Uname";
    private String pwd="Pword";
    public String getName()
    return name;
    public String getPwd()
    return pwd;
    void setName(String name)
    this.name = name;
    void setPwd(String pwd)
    this.pwd = pwd;
    <HTML>
    <BODY BGCOLOR="#FFFFFF">
    <%@ page language="java" contentType="text/html" %>
    <jsp:useBean id="b1" class="com.bluenile.bean.Bean1" />
    <ul>
    <li>Name : <jsp:getProperty name="b1" property="name" />
    <li>Pwd : <jsp:getProperty name="b1" property="pwd" />
    </ul>
    </BODY>
    </HTML>

  • HT1473 Im having problem while transferring songs from PC to Ipod. Ive followed all steps 'File Add to Library' but i cant find songs in my ipod. Ive also synced the ipod and backup as well but still same. what to do?

    Im having problem while transferring songs from PC to Ipod. Ive followed all steps 'File<Add to Library' but i cant find songs in my ipod. Ive also synced the ipod and backup as well but still same. what to do?

    Try:
    iTunes: Finding lost media and downloads
    iTunes: How to re-create your iTunes library and playlists
    Next try:
    Downloading past purchases from the App Store, iBookstore, and iTunes Store
    Also:
    Recovering your iTunes library from your iPod or iOS device: Apple Support Communities

  • Deriving Time Characteristics from Date fields in ODS View

    Hi,
    I am creating ODS Views using HANA calculation views.
    is there any direct approach to derive time characteristics like cal week, cal quarter, cal month, calmonth 2, fiscal year, cal year etc from date fields?
    work around:
    Deriving them in HANA view in calculated columns and mapping them to IO created with respective time characteristics as reference.
    is there any standard and easy to use approach for this??
    Thanks in advance.

    Hi Ravi,
    Insteod deriving them in the ODS view you can derive them in tha Calculation View in SAP HANA itself using Time Dimention concept.
    Regards
    Jagan

  • Rip of year from date field

    I have a question. I want to rip of the year from date field. For e.g if date is 01/02/2006 I want just the 01/02 which month and date. I tried to use substr function but it;s giving weird result. I used substr(date, 0,5) but not working. Please suggest.

    If it is a DATE column/variable it is conventional to use TO_CHAR with an appropriate date format, in your case TO_CHAR (date_column, 'MM/YY').

  • Tried to install OS X Yosemite on my MacBook. Got message that it could not be installed on my computer due to error while extracting files from package "Essentials.pkg". When i quit the installer as recommended it goes in a loop and gets stuck.

    Tried to install OS X Yosemite on my MacBook. Got message that it could not be installed on my computer due to error while extracting files from package "Essentials.pkg". When i quit the installer as recommended it goes in a loop and gets stuck.

    Hey corrafromlondon,
    Thanks for the question. After reviewing your post, it sounds like the installer file isn't working. Have you tried deleting the installer and redownloading the installer? I would recommend that you read this article, it may be able to help you isolate or resolve the issue.
    How to install OS X Yosemite on your Mac - Apple Support
    you can find the Yosemite installer app in your Applications folder or Launchpad. 
    Thanks for using Apple Support Communities.
    Have a nice day,
    Mario

  • FI-GL(Income Statements) problems while extracting from R/3?

    Hi Guru's,
    I will be working on FI-Gl(Income Statement) for the first time, could someone please tell me what problems i would face when getting data from R/3.
    I have read that they are few problems in transferring Special Ledger Data from R/3.
    Like:
    The option for “delta” updates was not chosen in view of the following limitations –
    •     The BALANCE field in the transfer structure will not be supplied with data during Delta upload. Special update rules will be required in order to populate the field.
    •     Deletion transactions are not connected to the Delta method.           
    Please do help me I will thank you guru's with assigning points.
    K3R

    Hi Prakash,
    Thanks for the early reply.
    When I check SAP Help, it tell me that 0FI_GL_1 has been replaced by 0FI_GL_6?
    Prakash : 0FI_GL_6 wont bring data for all currency types unless you specifically pull data for those currency types from your infopackae seletction (we are on BW 3.5)?
    K3R  :     We are also on BW 3.5. could please explain further regarding pulling data for currency from infopackage?
    I am trying to do the whole process of collecting data, creating Cubes and reports. As i have mentioned I am new to FI. Trying to understand the process.
    If you can give me any more details that would be very helpful.
    I have award points for your help.
    K3r

  • Extract Year (only) from Date Field and Display in Text Field

    I need to extract the year from a user entered date field and display the year in a text field. Can someone help me with the correct script to do this?

    Hi,
    that's quite easy to realize with FormCalc.
    In you date fields exit event add the following code:
    textField1 = Num2Date( Date2Num($.formattedValue, "MM/DD/YYYY"), "YYYY")
    Note: This sample assumes that your date field formats the date with "MM/DD/YYYY". You may have to change the pattern to make it work at your end.

  • Problem With Crystal Reports Reading Date Fields From CSV File

    I have a date field in a CSV file in the format 06/28/09 17:23:55.523. When I use ODBC the configuartion picks it up a character field. I overright the recommendation type by specifing it is a date field but whne I bring the data into crystal reports the dates are blanks. Any suggestions on how to get around this problem. I need to use the date for selection records.
    Phasor

    The question was answered under another thread. I had to use the split commmand to get rid of the fractions of a second

Maybe you are looking for

  • Should I or shouldn't I? buy I mean

    Ok I've got a imac from 2007 which came with Leopard on it, was new to Mac, and love it. Havent used everything on it yet! I bought iLife 09 as it came with iLife 08, and I liked the look of the new features of iLife 09;faces/places etc My iMac is "o

  • Want to gift playlist in itunes 10 for my daughter, but no arrow to click?

    My daughter is away at college and I wanted to send her a playlist from music I bought in iTunes. According to the instructions I should select the playlist and click the arrow to the right of the name and follow the instructions. There is no arrow.

  • GetXMLString java.lang.OutOfMemoryError

    Hello, I am trying to get data from tables and save this information in XML files. I am using XML SQL utility into a Java program. The problem is that I have a big table with a LONG data type and when the program try to get the data it shows an error

  • Menus appear glitchy on second monitor.

    I just started using a two monitor setup at my new job. Firefox 4 appears to work perfectly on the first monitor, but on the second monitor, right-click menus, the Firefox menu, bookmark toolbar folders, and anything else similar to that shows up fli

  • Additions required in portalapp.xml to import statements in JSPDynPage

    Hi all, What additions are required in portalapp.xml and import statements in JSPDynPage to include the equivalent of following JCO Clientservice in EP6 SP11? com.sap.portal.runtime.application.jcoclient.jcoclient The piece of code requiring the abov