Where emp.dept_id=nvl(dept_id,10)(+) conditions is failing,

select empno, ename from emp,dept
where dept.dept_id=emp.dept_id(+)
now
select empno,ename from emp, dept
where dept.dept_id=nvl(emp.dept_id,dept.dept_id)(+)
is throwing error
ORA-00936: missing expression
Can you please suggest how to do it
Thanks,

Dear,
select empno,ename from emp, dept
where dept.dept_id=nvl(emp.dept_id,dept.dept_id)(+)Could you please phrase what you want to get using the above query?
You are telling oralce to join dep to emp using dept_id; and you are also telling oracle that if the dept_id in emp is null then consider the dept.dept_id instaed. So in this case your query will ressemble to the following one
select empno,ename from emp, dept
where dept.dept_id=dept.dept_id(+)And hence you will be outer joinging two tables to each other wich is not possible
Best Regards
Mohamed Houri

Similar Messages

  • Where do you accept terms and conditions on iphone?

    Where do you accept terms and conditions on iphone after adding billing information? 

    Hey natedaniels07,
    Thanks for the question. I understand you are having issues accepting the Terms & Conditions. If you have not already done so, you may want to restart your iPhone:
    iOS: Turning off and on (restarting) and resetting
    http://support.apple.com/kb/HT1430
    If you are able to access the home screen, make sure cookies are not blocked and private browsing is turned off in Settings > Safari (you can also take this opportunity to Clear Cookies and Data):
    Safari settings - iPhone User Guide
    http://help.apple.com/iphone/7/#/iph3d7aa74dc
    Thanks,
    Matt M.

  • Generate a where clause with outer join criteria condition: (+)=

    Hi,
    In my search page, I use Auto Customization Criteria mode, and I build where clause by using get Criteria():
    public void initSrpQuery(Dictionary[] dic, String userName) {
    int dicSize = dic.length;
    StringBuffer whereClause = new StringBuffer(100);
    Vector parameters = new Vector(5);
    int clauseCount = 0;
    int bindCount = 1;
    for(int i=0; i < dicSize; i++){
    String itemName = (String)(dic.get(OAViewObject.CRITERIA_ITEM_NAME));
    Object value = dic[i].get(OAViewObject.CRITERIA_VALUE);
    String joinCondition = (String)dic[i].get(OAViewObject.CRITERIA_JOIN_CONDITION);
    String criteriaCondition = (String)dic[i].get(OAViewObject.CRITERIA_CONDITION);
    String criteriaDataType = (String)dic[i].get(OAViewObject.CRITERIA_DATATYPE);
    String viewAttributename = (String)dic[i].get(OAViewObject.CRITERIA_VIEW_ATTRIBUTE_NAME);
    String columnName = findAttributeDef(viewAttributename).getColumnNameForQuery();
    if((value != null) /*&& (!("".equals((String).trim())))*/){
    if(clauseCount > 0){
    whereClause.append(" AND ");
    whereClause.append(columnName + " " + criteriaCondition + " :");
    whereClause.append(++bindCount);
    parameters.addElement(value);
    clauseCount++;
    If I want to generate following where clause:
    select
    ,emp.name
    ,emp.email
    ,emp.salesrep_number
    ,comp.name
    ,gs.srp_goal_header_id
    ,gs.status_code
    ,gs.start_date
    ,gs.end_date
    from g2c_goal_shr_emp_assignments_v emp
    ,jtf_rs_salesreps rs
    ,xxg2c_srp_goal_headers_all gs
    ,cn_comp_plans_all comp
    where 1 = 1
    and rs.salesrep_id = gs.salesrep_id (+)
    and gs.comp_plan_id = comp.comp_plan_id (+)
    and gs.period_year (+) = :1 -- :1 p_fiscal_year
    How can I generate a where clause with outer join : gs.period_year (+) = :1 ? Will I get '(+)=' from get(OAViewObject.CRITERIA_CONDITION)?
    thanks
    Lei

    If you are using SQL-Plus or Reports you can use lexical parameters like:
    SELECT * FROM emp &condition;
    When you run the query it will ask for value of condition and you can enter what every you want. Here is a really fun query:
    SELECT &columns FROM &tables &condition;
    But if you are using Forms. Then you have to change the condition by SET_BLOCK_PROPERTY.
    Best of luck!

  • Where are the Community terms and conditions?

    I've looked and can't seem to find them.  The web page: http://www.apple.com/legal/terms/site.html has an entry for 'Discussions Terms and Conditions' which is: https://discussions.apple.com/help.jspa.  That link results in a page titled help but is void of content.
    Is there any other specific place I should look?

    John Maisey wrote:
    Hi,
    They are here:
    https://discussions.apple.com/___sbsstatic___/apple/tutorial/tou.html
    That page is linked to at the bottom of each page on this forum.
    Also see:
    https://discussions.apple.com/___sbsstatic___/apple/tutorial/etiquette.html
    Best wishes
    John M
    Thanks for the direct pointers.  I do believe that they are important enough that they shouldn't be buried in the tutorials but readily available from a higher level.
    I was able to find the etiquette link under the tutorial "Asking questions" but so far I haven't found a place where the TOU is linked from.  Am I missing something obvious or is it, too, buried somewhere?

  • Whats the meaning of plus in query : select employeename from emp where emp

    Hi All,
    Can someone please explain me whats the meaning of plus sign in following SQL. I have nevercome across this syntax
    select employeename from emp where empid(+) >= 1234.

    Example of equivalent queries using oracle syntax and ansi syntax
    SQL> ed
    Wrote file afiedt.buf
      1  select d.deptno, d.dname, e.ename
      2  from dept d, emp e
      3* where d.deptno = e.deptno (+)
    SQL> /
        DEPTNO DNAME          ENAME
            20 RESEARCH       SMITH
            30 SALES          ALLEN
            30 SALES          WARD
            20 RESEARCH       JONES
            30 SALES          MARTIN
            30 SALES          BLAKE
            10 ACCOUNTING     CLARK
            20 RESEARCH       SCOTT
            10 ACCOUNTING     KING
            30 SALES          TURNER
            20 RESEARCH       ADAMS
            30 SALES          JAMES
            20 RESEARCH       FORD
            10 ACCOUNTING     MILLER
            40 OPERATIONS
    15 rows selected.
    SQL> ed
    Wrote file afiedt.buf
      1  select d.deptno, d.dname, e.ename
      2* from dept d left outer join emp e on (d.deptno = e.deptno)
    SQL> /
        DEPTNO DNAME          ENAME
            20 RESEARCH       SMITH
            30 SALES          ALLEN
            30 SALES          WARD
            20 RESEARCH       JONES
            30 SALES          MARTIN
            30 SALES          BLAKE
            10 ACCOUNTING     CLARK
            20 RESEARCH       SCOTT
            10 ACCOUNTING     KING
            30 SALES          TURNER
            20 RESEARCH       ADAMS
            30 SALES          JAMES
            20 RESEARCH       FORD
            10 ACCOUNTING     MILLER
            40 OPERATIONS
    15 rows selected.
    SQL>

  • TAXINN SD For Excise Duty where to maintain TAX CODE in condition record?

    is Tax code necessary for excise determination in TAXINN in SD Scenario? While maintaining condition record ( JEXP) for Excise access sequence JEXC doesnu2019t has Tax Code field Whereas for Sale Tax determination ( JCST/JLST) access sequence JLST /CST which has Tax code field . (In TAXINN we create Dummy tax code (blank))
    is it true whatever I have written ? If yes then what is use of tax code where it triggers in FI Posting? Why we use only for Sale Tax not for Excise duty?
    If u go to SAP Std condition type & access sequence provide for CIN in SD (TAXINN) While maintaining condition record ( JEXP) for Excise. Access sequence JEXC doesnu2019t has Tax Code field . do u think we should modify that create field for Tax code ..... Pl check in system & answer the question .......I hope u understand what i want to ask.

    Hi,
    As per my knowledge, Excise is not Tax its a Duty....
    Excise gets added to your base price and the tax is calculated on the whole amount and not only the basic price.
    Say if u r manufacturing a material and u r under excise regulations, then without paying excise duty you can't move the goods out of your premises, Here even before you sell the material to a customer the excise duty is paid from you. But when u will be selling the material to a customer, the customer is charged the excise duty which gets added to the net value and then the sales tax is calculated.
    If u see a sale order condition tab page, there are two fields
    1. Net Value      2. Tax
    Net value is the value which includes the excise duty and the tax is only the CST/LST/VAT.
    Regards

  • Where can I sell my great condition 15" Powerbook w/ lots of software?

    I need to sell my laptop to purchase a PC (for my job). I have tried listing it on craigslist.com and eBay but had little response. Does anyone know where a better place to sell it would be? It is in immaculate condition and was purchased w/ all the software for over $3000. I am selling for $1250. Any help would be appreciated.

    The price you should expect to get for your TiBook will depend on which model you have and how "pimped out" it is. A 1GHz TiBook will fetch the most, but you didn't specify which model you are selling, the condition it's in, and what comes with it.
    A quick check of eBay seems to indicate that TiBooks are not really moving anymore. I suspect that the release of the Mactel Powerbook, as well as the newer 1.67GHz PowerPC Powerbook, has pretty much killed the used market for TiBooks. People can pick up a nice 1.5GHz AlBook for about $1500, now, and that PB has USB 2.0, can handle more RAM, comes with a larger and faster hard drive, and supports Airport Extreme, as well as having many other improvements over the TiBook. Deciding to spend $1200 for your PB vs. $1400 for that one seems like a no-brainer.
    I did see one TiBook on eBay that had two bids and a current price of $2000, but I suspect that one was "bid-inflated", as no other TiBook 1GHz that I saw came even close to that. $900 would be a reasonable price, but I think you might be lucky to get even that. I'm thinking $700-800 might be more likely.
    One thing to keep in mind: Bundling software does NOT really increase value, unless the versions you're including are pretty close to recent and you're including the original installation disks. Most people who buy used Macs wipe the hard drives and start all over, so if you're only including "pre-installed" software, don't even waste your time.
    Good luck, though!

  • Where can I find terms and conditions of purchasing magazine?

    I can't remember for how long I subscribed for my cosmopolitan magazine.
    I would like to find terms and contions for magazine subscription...

    In iTunes. Usually when you first purchase it.

  • Selective (Conditional) export failing with ORA-00936: missing expression

    HI Experts,
    I was doing selective (Conditional) export of one table. But the export is failing with the following error.
    ORA-00936: missing expression
    I have been trying for the past 2 hours on this to resolve. But not.
    Could anybody please how can i export the data..
    Oracle Version : 10.2.0.5
    OS : SOLARIS 10 SPARC
    exp E3DAIUSR/E3DAIUSR@ORCL statistics=none file=exp_TABLE.dmp log=exp_Conditional.log TABLES=PGTB_IFDATA query=\'where CRE_DT=\''20120513\'
    The error is as follows
    ==============
    About to export specified tables via Conventional Path ...
    . . exporting table PGTB_IFDATA
    EXP-00056: ORACLE error 936 encountered
    ORA-00936: missing expression
    Export terminated successfully with warnings.
    Please help me on this..

    Hi ,
    Now i am using the query like below. But still getting the error.
    exp E3DAIUSR/E3DAIUSR@ORCL statistics=none file=exp_TD17870_1_TABLE.dmp log=exp_TD17870_1_TABLE_Conditional.log TABLES=PGTB_IFDATA query=\"where CRE_DT=\'20120513\'"
    Error
    ====
    LRM-00111: no closing quote for value 'where CRE_'
    EXP-00019: failed to process parameters, type 'EXP HELP=Y' for help
    EXP-00000: Export terminated unsuccessfully
    This is Solaris OS
    Please provide me correct query if possible

  • Flash Builder 4.7 conditional compiling failed

    I installed Flash Builder 4.7 on my windows xp machine, and tried to migrate projects from FB 4.6. However in one of my projects I use conditional compiling, but I'm getting errors.For example in FB 4.6 I have this sample code:
    public class MyClass{
         CONFIG::DEBUGGING{
              import com.package.SomeClassOnlyForDebugging
         function someFunction():void{
              if (CONFIG::DEBUGGING){
                   SomeClassOnlyForDebugging.create();
    When I compiled it in FB 4.6 everything worked fine. However when I try to compile it in FB 4.7, then I get error on the conditional compiling only inside the function and not on the import statement. The only way I have found to overpass it is to go to Project>Properties>ActionScript Compiler and disable Enable strict type checking. But this is not a permanent solution.
    Am I doing something wrong, or is there some other way to do it?

    You should to do like that:
    function someFunction():void
    CONFIG::DEBUGGING {
         SomeClassOnlyForDebugging.create();
    without if.

  • Need to Disable a link when a condition is failed in Web dynpro ABAP

    HI Gurus,
      I have an requirement, I am displaying one form, above the form I am displaying the link as  Overview. if some conditions failed and the form is not displayed, I want to disable that link ' OVERVIEW" should be in disable mode.
    Please provide the code how to approach this.
    Thanks
    Rahul

    Hi Radhika,
    Thanks for the Response.
    I wrote the below code for making the link disable.
    data lv_link_disable like ls_context-link_disable.
    get element via lead selection
        lo_el_context = wd_context->get_element(  ).
    get element via lead selection
        lo_el_context = wd_context->get_element( ).
    fill attribute
        lv_link_disable = abap_false.
    set single attribute
        lo_el_context->set_attribute(
        name = `LINK_DISABLE`
        value = lv_link_disable ).
    But unfortunately its not wokring.
    Can you please let me know what I need to add to this.
    Thanks
    Rahul

  • Where are my games (following a hard disk fail)

    I have a Macbook V1 and have been religiously backing up my machine from the moment I bought it. Last weekend the hard drive failed. I have reinstalled OSX (using the same naming conventions), fully updated it to the latest version and imported all my music files into iTunes. However, I had all the games and can't find any of those to import.
    Could someone please tell me where they are or, alternatively, offer a better way of reinstating my iTunes library given the fact that I have everything backed up to an external drive.
    Many thanks
    Macbook   Mac OS X (10.4.8)  

    The games are located by default in:
    Home > Music > iTunes > iPod Games folder
    You can do a spotlight search on files with the ".ipg" extension as well.

  • RAID card battery conditioning - "Battery failed (other than expired)"

    OK, so if you log-in using the GUI, you get a warning telling you that battery conditioning is happening and that you shouldn't the server.
    However, if you log-in over SSH, as you might, for instance, with a headless Xserve, you don't get that warning. And then, if you restart more than a certain number of times, for instance because you're installing all the software updates that the server has missed while it hasn't been switched on, you end up in the following state:
    $ raidutil list status
    Apple raidutil version: 1.2.0
    General Status: Issues Found
    Battery fault. See Battery Status below.
    Battery Status: Battery failed (other than expired)
    Controller #1: Hardware Version 2.00/Firmware E-1.3.2.0
    Write Cache disabled
    Plainly this is undesirable.
    Does anyone know how to reset the battery state, preferably without having to pull the server out of its rack and disconnect the RAID card battery?
    Also, since when was it in any way reasonable to tell a user that they can't shut their machine down for 24 hours? Even with a server, that's ridiculous - sometimes you just have to reboot.
    Kind regards,
    Alastair.

    FWIW, I just filed rdar://7653429 about the fact that terminal users don't get any warning of this, and rdar://7653468 about the fact that battery conditioning shouldn't force sysadmins to keep their machine running for the next 24 hours (since they might really need to shut it down, right now).

  • Workflow Condition Step Failing

    Hi All,
    I am facing a very peculiar error.
    I have two outcomes modelled  depending on a varible (Material Type) in the worklfow.
    My workflow gets triggered when I push SUBMIT button on my ADOBE interactive form on ABAP Web Dynpro launcehd
    from UWL. Now if i check the workflow container, the variable is set properly. But still the condition fails. A backgorund task
    having import parameters as Owrkflow container elements fails with an exception even though the import parameters are set.
    But yes, again the workflow container same elements can be displayed on any form in further steps by reading the container
    from ABAP webDynpro launched from UWL. Peculiar !!!
    The same workflow works fine if I directly set the variables and test the workflow.
    Why this ?..... Any Idea.... ? If something is written on to the workflow container can the workflow work on those variables ?
    Please suggest.
    Thanks & Regards,
    Deb

    Hi Rick,
    Thanks for your suggestions. Actually we could solve it ina different way. It was a nice but tricky error in muy coding.
    Here is what I was doing:
    1)  I tirgger my workflow on click of 'SUBMIT' button on my ADOBE interactive in AWD
    2) Then I get the instance of the workflow to get the Workflow Work Item ID
    3) Now I write the form data to the workflow container.
    Note: By the time I write to my container, my workflow had been already triggered, with the condition step at the 1st.
             And the container is not yet written, hence the condition fails.
    Solution:  I used a wait step. And Read the workflow container in loop untill the container elements are populated.
                   Once out of this loop, I now tirgger the write to the container and raise the wait event.
    Cheers !!
    Deb

  • Error:Returning to application. Exception: com.sap.aii.adapter.xi.routing.RoutingException: Can't determine receivers because condition evaluation failed

    my requiremant is one sender and based on receiver detremination condition it should go to many receivers.
    Just to elaborate the requirement.
    Observe the Xpath example below:
    <Identifier>
        <Name>abc</Name>
        <Value>first</Value>
    </Identifier>
      <Identifier>
        <Name>cdf</Name>
        <Value>come</Value>
       </Identifier>
       <Identifier>
        <Name>ten</Name>
        <Value>go</Value>
       </Identifier>
    Now am using the following Xpath.
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[1] ≈ abc  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[1] ≈ first  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[2] ≈ cdf  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[2] ≈ come AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[3] ≈ ten  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[3] ≈ go
    any suggestions for the correct xpath are welcome
    thanks in advance

    Hi,
    so you want to trigger based on the below condition
    Receiver 1
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[1] ≈ abc  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[1] ≈ first  or
    Receiver 2
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[2] ≈ cdf  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[2] ≈ come or
    receiver 3
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Name[3] ≈ ten  AND
    /p1:MT_fd/MessageHeader/OtherArea/Identifier/Value[3] ≈ go
    so please apply this condition to different receiver service. Or if it is for one then put or in between the condition

Maybe you are looking for

  • Need help with Kerb. jdbc from Linux to MS SQL 2008

    Hello Forum, I am getting an erro when I try to use Kerb. trusted security to connect to sql server. 4.0 documentation reflects it's absolutely possible. Not only that, I have ms odbc installed on the same box and it provides Kerbers (not ntlm) conne

  • Repeating regions - won't allow

    I have to make 7 rows of these and it would be a lot easier, and better to know the way to do it, to make one row a repeating region. When I select everything in the row and choose make a repeating region I get a dialog that says its already and edit

  • Firefox, most of window is blacked out, menues area is transparent, menus not visible. Website is loading behind blackout. Complete uninstall has been tried.

    The problem started after doing a Windows 7 disk cleanup. When I open Firefox the screen where the body of the website is is blacked out and the menu bars are not visible. I can tell Firefox and websites are loading because I can guess where address

  • Oracle Instance Termination

    Dear Sir/Madam We were having Oracle 8.1.5 server in WinNT 4.0 with 1GB RAM and 52GB HD. Our sites has more than 30 users and we were having the application in PB.In our place Database Instance Terminating at frequent intervals.When I monitored the A

  • Dilemma with Backing Up

    I currently have a 1TB HITACHI external hard drive that contains essential files and back ups of 3 PCs in my house. I have a MacBook Pro and I'm looking to back it up. I would like to use the Time Capsule utility, but I am told this will erase all da