Limitation that only 1000 records can be included in the "IN" clause

In RapidSQL we have a limitation that only 1000 records can be included in the "IN" clause - is there a way to give more than 1000 records so that it will reduce the execution time.

Why do you need to list more than 1000 individual items in the first place? That's generally not a good way to go about building a query.
You can always include a query that returns as many rows as you'd like in an IN clause, i.e.
SELECT *
  FROM some_table
WHERE some_column IN (SELECT some_column FROM some_other_table)So if you throw the thousands of values you want in the IN list into a table, you could then query the table in your IN clause.
From a performance standpoint, of course, you may also want to look at the EXISTS clause depending on the relative data volumes involved.
Justin

Similar Messages

  • RetrieveLimitedRecordsCommand retrieving only 1000 records

    Hi All,
    While I am trying to retrieve records from the main table using RetrieveLimitedRecordsCommand I am getting only 1000 records from MDM, where as there are around 100000 records in the table.
    Could anyone help in this regard.
    Thanks and Regards,
    Subhasis

    The default page size is set to 1000, so if you have more than 1000 records, customize your code to increase the page size in loop.
    Here is how we did:
    Get the count total records = n //use the method getSearchTableMatchCount() on RetrieveLimitedRecordsExCommand
    int n = retrieveLimitedRecordsExCommand.getSearchTableMatchCount( ) ;
    Number of pages or Page size p
    int p = N / 1000 ;
    for( int i=1; i<=p ; i++ )
        //Now loop through the retrieve command from 1 to p and inside the loop take the records in an array.
    Now either you can implement it this way to get all the records in one shot. Or you can implement custom pagination on your table/result set view to retrieve the next 1000 records as required.
    And if you implement your custom pagination, you can also set the page size as per your design.
    Regards
    Nitin

  • Can I Lock an Ipod So That Only One Computer Can Use It?

    So I just bought my grandma an ipod and plan on putting all of her music and such on it for her. What I want to do is make it so that only my computer can access the files and if another computer tried to use the ipod it would lock, I don't want to use the screen lock either. Is there any way to do this through iTunes or not? Thanks alot.

    Oh, I'm so sorry.
    Dear jmentzer262,
    Your brilliant plan cannot be put into action I'm afraid. Apple have not seen fit to include this feature. I'm so sorry that we cannot help you implement this.
    There is no doubt that we here are not worthy, and I for one will try my utmost to do better in answering any of your questions in the future.
    I understand that when answering a question it is not sufficient to say "it can't be done", as I realise that when dealing with someone is so sensitive we must temper our replies accordingly.
    Please accept my humble apologies for my "attitude" and you can rest assured that I have punished myself severely for this unacceptable lapse of judgement. Can you ever find it in your heart to forgive me?

  • Bulk collect limit 1000 is looping only 1000 records out of 35000 records

    In below code I have to loop around 35000 records for every month of the year starting from Aug-2010 to Aug-2011.
    I am using bulk collect with limit clause but the problem is:
    a: Limit clause is returning only 1000 records.
    b: It is taking too much time to process.
    CREATE OR REPLACE PACKAGE BODY UDBFINV AS
    F UTL_FILE.FILE_TYPE;
    PV_SEQ_NO NUMBER(7);
    PV_REC_CNT NUMBER(7) := 0;
    PV_CRLF VARCHAR2(2) := CHR(13) || CHR(10);
    TYPE REC_PART IS RECORD(
    PART_NUM PM_PART_HARSH.PART_NUM%TYPE,
    ON_HAND_QTY PM_PART_HARSH.ON_HAND_QTY%TYPE,
    ENGG_PREFIX PM_PART_HARSH.ENGG_PREFIX%TYPE,
    ENGG_BASE PM_PART_HARSH.ENGG_BASE%TYPE,
    ENGG_SUFFIX PM_PART_HARSH.ENGG_SUFFIX%TYPE);
    TYPE TB_PART IS TABLE OF REC_PART;
    TYPE REC_DATE IS RECORD(
    START_DATE DATE,
    END_DATE DATE);
    TYPE TB_MONTH IS TABLE OF REC_DATE;
    PROCEDURE MAIN IS
    /* To be called in Scheduler Programs Action */
    BEGIN
    /* Initializing package global variables;*/
    IFMAINT.V_PROG_NAME := 'FULL_INVENTORY';
    IFMAINT.V_ERR_LOG_TAB := 'UDB_ERR_FINV';
    IFMAINT.V_HIST_TAB := 'UDB_HT_FINV';
    IFMAINT.V_UTL_DIR_NAME := 'UDB_SEND';
    IFMAINT.V_PROG_TYPE := 'S';
    IFMAINT.V_IF_TYPE := 'U';
    IFMAINT.V_REC_CNT := 0;
    IFMAINT.V_DEL_INS := 'Y';
    IFMAINT.V_KEY_INFO := NULL;
    IFMAINT.V_MSG := NULL;
    IFMAINT.V_ORA_MSG := NULL;
    IFSMAINT.V_FILE_NUM := IFSMAINT.V_FILE_NUM + 1;
    IFMAINT.LOG_ERROR; /*Initialize error log table, delete prev. rows*/
    /*End of initialization section*/
    IFMAINT.SET_INITIAL_PARAM;
    IFMAINT.SET_PROGRAM_PARAM;
    IFMAINT.SET_UTL_DIR_PATH;
    IFMAINT.GET_DEALER_PARAMETERS;
    PV_SEQ_NO := IFSMAINT.GENERATE_FILE_NAME;
    IF NOT CHECK_FILE_EXISTS THEN
    WRITE_FILE;
    END IF;
    IF IFMAINT.V_BACKUP_PATH_SEND IS NOT NULL THEN
    IFMAINT.COPY_FILE(IFMAINT.V_UTL_DIR_PATH,
    IFMAINT.V_FILE_NAME,
    IFMAINT.V_BACKUP_PATH_SEND);
    END IF;
    IFMAINT.MOVE_FILE(IFMAINT.V_UTL_DIR_PATH,
    IFMAINT.V_FILE_NAME,
    IFMAINT.V_FILE_DEST_PATH);
    COMMIT;
    EXCEPTION
    WHEN IFMAINT.E_TERMINATE THEN
    IFMAINT.V_DEL_INS := 'N';
    IFMAINT.LOG_ERROR;
    ROLLBACK;
    UTL_FILE.FCLOSE(F);
    IFMAINT.DELETE_FILE(IFMAINT.V_UTL_DIR_PATH, IFMAINT.V_FILE_NAME);
    RAISE_APPLICATION_ERROR(IFMAINT.V_USER_ERRCODE, IFMAINT.V_ORA_MSG);
    WHEN OTHERS THEN
    IFMAINT.V_DEL_INS := 'N';
    IFMAINT.V_MSG := 'ERROR IN MAIN PROCEDURE ||IFMAINT.V_PROG_NAME';
    IFMAINT.V_ORA_MSG := SUBSTR(SQLERRM, 1, 255);
    IFMAINT.V_USER_ERRCODE := -20101;
    IFMAINT.LOG_ERROR;
    ROLLBACK;
    UTL_FILE.FCLOSE(F);
    IFMAINT.DELETE_FILE(IFMAINT.V_UTL_DIR_PATH, IFMAINT.V_FILE_NAME);
    RAISE_APPLICATION_ERROR(IFMAINT.V_USER_ERRCODE, IFMAINT.V_ORA_MSG);
    END;
    PROCEDURE WRITE_FILE IS
    CURSOR CR_PART IS
    SELECT A.PART_NUM, ON_HAND_QTY, ENGG_PREFIX, ENGG_BASE, ENGG_SUFFIX
    FROM PM_PART_HARSH A;
    lv_cursor TB_PART;
    LV_CURR_MONTH NUMBER;
    LV_MONTH_1 NUMBER := NULL;
    LV_MONTH_2 NUMBER := NULL;
    LV_MONTH_3 NUMBER := NULL;
    LV_MONTH_4 NUMBER := NULL;
    LV_MONTH_5 NUMBER := NULL;
    LV_MONTH_6 NUMBER := NULL;
    LV_MONTH_7 NUMBER := NULL;
    LV_MONTH_8 NUMBER := NULL;
    LV_MONTH_9 NUMBER := NULL;
    LV_MONTH_10 NUMBER := NULL;
    LV_MONTH_11 NUMBER := NULL;
    LV_MONTH_12 NUMBER := NULL;
    lv_month TB_MONTH := TB_MONTH();
    BEGIN
    IF CR_PART%ISOPEN THEN
    CLOSE CR_PART;
    END IF;
    FOR K IN 1 .. 12 LOOP
    lv_month.EXTEND();
    lv_month(k).start_date := ADD_MONTHS(TRUNC(SYSDATE, 'MM'), - (K + 1));
    lv_month(k).end_date := (ADD_MONTHS(TRUNC(SYSDATE, 'MM'), -K) - 1);
    END LOOP;
    F := utl_file.fopen(IFMAINT.V_UTL_DIR_NAME, IFMAINT.V_FILE_NAME, 'W');
    IF UTL_FILE.IS_OPEN(F) THEN
    /*FILE HEADER*/
    utl_file.put_line(F,
    RPAD('$CUD-', 5, ' ') ||
    RPAD(SUBSTR(IFMAINT.V_PANDA_CD, 1, 5), 5, ' ') ||
    RPAD('-136-', 5, ' ') || RPAD('000000', 6, ' ') ||
    RPAD('-REDFLEX-KA-', 13, ' ') ||
    RPAD('00000000-', 9, ' ') ||
    RPAD(IFMAINT.V_CDS_SPEC_REL_NUM, 5, ' ') ||
    RPAD('CD', 2, ' ') ||
    RPAD(TO_CHAR(SYSDATE, 'MMDDYY'), 6, ' ') ||
    LPAD(IFSMAINT.V_FILE_NUM, 2, 0) ||
    RPAD('-', 1, ' ') || RPAD(' ', 9, ' ') ||
    RPAD('-', 1, ' ') || RPAD(' ', 17, ' ') ||
    RPAD('CD230', 5, ' ') ||
    RPAD(TO_CHAR(SYSDATE, 'MMDDYY'), 6, ' ') ||
    LPAD(IFSMAINT.V_FILE_NUM, 2, 0) ||
    LPAD(PV_REC_CNT, 8, 0) || RPAD(' ', 5, ' ') ||
    RPAD('00000000', 8, ' ') || RPAD('CUD', 3, ' ') ||
    RPAD(IFMAINT.V_CDS_SPEC_REL_NUM, 5, ' ') ||
    RPAD(IFMAINT.V_GEO_SALES_AREA_CD, 3, ' ') ||
    RPAD(IFMAINT.V_FRANCHISE_CD, 2, ' ') ||
    RPAD(IFMAINT.V_DSP_REL_NUM, 9, ' ') ||
    RPAD('00136REDFLEX', 12, ' ') || RPAD(' ', 1, ' ') ||
    RPAD('KA', 2, ' ') || RPAD('000000', 6, ' ') ||
    RPAD('00D', 3, ' ') ||
    RPAD(IFMAINT.V_VENDOR_ID, 6, ' ') ||
    RPAD(IFSMAINT.V_FILE_TYPE, 1, ' ') ||
    RPAD('>', 1, ' ') || PV_CRLF);
    /*LINE ITEMS*/
    OPEN CR_PART;
    FETCH CR_PART BULK COLLECT
    INTO lv_cursor limit 1000;
    FOR I IN lv_cursor.FIRST .. lv_cursor.LAST LOOP
    SELECT SUM(A.BILL_QTY)
    INTO LV_CURR_MONTH
    FROM PD_ISSUE A, PH_ISSUE B
    WHERE A.DOC_TYPE IN ('CRI', 'RRI', 'RSI', 'CSI')
    AND A.DOC_NUM = B.DOC_NUM
    AND B.DOC_DATE BETWEEN TRUNC(SYSDATE, 'MM') AND SYSDATE
    AND A.PART_NUM = LV_CURSOR(i).PART_NUM;
    FOR J IN 1 .. 12 LOOP
    SELECT SUM(A.BILL_QTY)
    INTO LV_MONTH_1
    FROM PD_ISSUE A, PH_ISSUE B
    WHERE A.DOC_TYPE IN ('CRI', 'RRI', 'RSI', 'CSI')
    AND A.DOC_NUM = B.DOC_NUM
    AND B.DOC_DATE BETWEEN lv_month(J).start_date and lv_month(J)
    .end_date
    AND A.PART_NUM = LV_CURSOR(i).PART_NUM;
    END LOOP;
    utl_file.put_line(F,
    RPAD('IL', 2, ' ') ||
    RPAD(TO_CHAR(SYSDATE, 'RRRRMMDD'), 8, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_PREFIX, 6, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_BASE, 8, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_SUFFIX, 6, ' ') ||
    LPAD(LV_CURSOR(I).ON_HAND_QTY, 7, 0) ||
    LPAD(NVL(LV_CURR_MONTH, 0), 7, 0) ||
    LPAD(LV_MONTH_1, 7, 0) || LPAD(LV_MONTH_2, 7, 0) ||
    LPAD(LV_MONTH_3, 7, 0) || LPAD(LV_MONTH_4, 7, 0) ||
    LPAD(LV_MONTH_5, 7, 0) || LPAD(LV_MONTH_6, 7, 0) ||
    LPAD(LV_MONTH_7, 7, 0) || LPAD(LV_MONTH_8, 7, 0) ||
    LPAD(LV_MONTH_9, 7, 0) || LPAD(LV_MONTH_10, 7, 0) ||
    LPAD(LV_MONTH_11, 7, 0) ||
    LPAD(LV_MONTH_12, 7, 0));
    IFMAINT.V_REC_CNT := IFMAINT.V_REC_CNT + 1;
    END LOOP;
    CLOSE CR_PART;
    /*TRAILER*/
    utl_file.put_line(F,
    RPAD('$EOF-', 5, ' ') || RPAD('320R', 4, ' ') ||
    RPAD(SUBSTR(IFMAINT.V_PANDA_CD, 1, 5), 5, ' ') ||
    RPAD(' ', 5, ' ') ||
    RPAD(IFMAINT.V_GEO_SALES_AREA_CD, 3, ' ') ||
    RPAD(TO_CHAR(SYSDATE, 'MM-DD-RR'), 6, ' ') ||
    LPAD(IFSMAINT.V_FILE_NUM, 2, 0) ||
    LPAD(IFMAINT.V_REC_CNT, 8, 0) || 'H' || '>' ||
    IFMAINT.V_REC_CNT);
    utl_file.fclose(F);
    IFMAINT.INSERT_HISTORY;
    END IF;
    END;
    FUNCTION CHECK_FILE_EXISTS RETURN BOOLEAN IS
    LB_FILE_EXIST BOOLEAN := FALSE;
    LN_FILE_LENGTH NUMBER;
    LN_BLOCK_SIZE NUMBER;
    BEGIN
    UTL_FILE.FGETATTR(IFMAINT.V_UTL_DIR_NAME,
    IFMAINT.V_FILE_NAME,
    LB_FILE_EXIST,
    LN_FILE_LENGTH,
    LN_BLOCK_SIZE);
    IF LB_FILE_EXIST THEN
    RETURN TRUE;
    END IF;
    RETURN FALSE;
    EXCEPTION
    WHEN OTHERS THEN
    RETURN FALSE;
    END;
    END;

    Try this:
    OPEN CR_PART;
    loop
    FETCH CR_PART BULK COLLECT
    INTO lv_cursor limit 1000;
    exit when CR_PART%notfound;
    FOR I IN lv_cursor.FIRST .. lv_cursor.LAST LOOP
    SELECT SUM(A.BILL_QTY)
    INTO LV_CURR_MONTH
    FROM PD_ISSUE A, PH_ISSUE B
    WHERE A.DOC_TYPE IN ('CRI', 'RRI', 'RSI', 'CSI')
    AND A.DOC_NUM = B.DOC_NUM
    AND B.DOC_DATE BETWEEN TRUNC(SYSDATE, 'MM') AND SYSDATE
    AND A.PART_NUM = LV_CURSOR(i).PART_NUM;
    FOR J IN 1 .. 12 LOOP
    SELECT SUM(A.BILL_QTY)
    INTO LV_MONTH_1
    FROM PD_ISSUE A, PH_ISSUE B
    WHERE A.DOC_TYPE IN ('CRI', 'RRI', 'RSI', 'CSI')
    AND A.DOC_NUM = B.DOC_NUM
    AND B.DOC_DATE BETWEEN lv_month(J).start_date and lv_month(J)
    .end_date
    AND A.PART_NUM = LV_CURSOR(i).PART_NUM;
    END LOOP;
    utl_file.put_line(F,
    RPAD('IL', 2, ' ') ||
    RPAD(TO_CHAR(SYSDATE, 'RRRRMMDD'), 8, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_PREFIX, 6, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_BASE, 8, ' ') ||
    RPAD(LV_CURSOR(I).ENGG_SUFFIX, 6, ' ') ||
    LPAD(LV_CURSOR(I).ON_HAND_QTY, 7, 0) ||
    LPAD(NVL(LV_CURR_MONTH, 0), 7, 0) ||
    LPAD(LV_MONTH_1, 7, 0) || LPAD(LV_MONTH_2, 7, 0) ||
    LPAD(LV_MONTH_3, 7, 0) || LPAD(LV_MONTH_4, 7, 0) ||
    LPAD(LV_MONTH_5, 7, 0) || LPAD(LV_MONTH_6, 7, 0) ||
    LPAD(LV_MONTH_7, 7, 0) || LPAD(LV_MONTH_8, 7, 0) ||
    LPAD(LV_MONTH_9, 7, 0) || LPAD(LV_MONTH_10, 7, 0) ||
    LPAD(LV_MONTH_11, 7, 0) ||
    LPAD(LV_MONTH_12, 7, 0));
    IFMAINT.V_REC_CNT := IFMAINT.V_REC_CNT + 1;
    END LOOP;
    end loop;
    CLOSE CR_PART;

  • Regarding Select query to select only 1000 records in Internal Table.

    Hello Friends,
    Please explain me to how to Select only 1000 records from data base table?
    For Example
    SELECT *  INTO TABLE ITAB                          OR            SELECT * INTO ITAB 
         FROM EKKO                                                                  FROM EKKO
    WHERE EBLEN IN S_EBLEN.                                            WHERE EBLEN IN S_EBLEN
    (Currently i am using)                                                       UP TO 1000 ROWS.
                                                                                    ENDSELECT.  (I do not want to use)
                                                                                    In this case Internal table may be store more then 1000 records. But i want to select first 1000 records.
    Please explain me.
    Regards
    Amit

    Hi,
    TABLES : ekko.
    selection-screen begin of block b1 with frame title text_t01.
    SELECT-OPTIONS: S_EBELN for ekko-EBELN.
    selection-screen end of block b1.
    DATA itab TYPE STANDARD TABLE OF ekko.
    SELECT *
      FROM ekko
      INTO TABLE itab
      UP TO 1000 ROWS
      WHERE EBELN IN S_EBELN.
    Thanks,
    Sri.

  • There a lot of accounts of apple,where are many games,these accounts are sold every day,i know that only 5 person can download one app,i want to know why this accounts are not blocked

    There a lot of accounts of apple,where are many games,these accounts are sold every day,i know that only 5 person can download one app,i want to know why this accounts are not blocked

    This is not a technical question, and discussions of Apple's policies are not appropriate here. If you have some sort of problem with your own iTunes Store account, by all means let us know and we may be able to help you, but otherwise this question is not one we can discuss in these forums.
    Regards.

  • Can I create pages that only authorized users can access?

    I need to create pages that only authorized users can access, is that possible to be done with Muse? 

    Hi Natalia,
    If you are using Business Catalyst as a host , then "Yes" you need to publish a website to use Secure zone of Business Catalyst.
    If you are using a different host or BC then you may use third party widgets like
    Adobe Muse Password Protection Widget | MuseThemes.com
    Thanks
    Prabhakar Kumar

  • Using Pro Logic X to record. I have several tracks and I'm trying to record an audio track. I have the mic connect to Avalon 737 then into apollo interface. When I record all track are being recorded into that track. I can't just get the audio to record.

    Using Pro Logic X to record. I have several tracks and I'm trying to record an audio track. I have the mic connect to Avalon 737 then into apollo interface. When I record all track are being recorded into that track. I can't just get the audio to record.

    Thanks for responding. Everything seems to work right except for the when I plug into the 737. Ok let me see if I can be more clear. I had this set up done with two representatives of Neumann, and DBox. Here it is I hope this helps. 32 Channel snake (24 Inputs 8 outputs) Channels 1-8 from snake to my Octopre for Drums. From Octropre output quarter inch lines into the Apollo 2, quarter inch input. This is so that the Apollo 2 is taking the drum tracks. Snake Channel 9-12 into Apollo 1 channels 1-4 xlr. Snake Channel 13-16 into Apollo 2 Channels 1-4 xlr. Snake Channel 17 into the 737, output of 737 into Channel 5 of the Apollo 1 quarter inch.
    Ok The Dbox. Sum output L&R into channel input 7&8 of Apollo 1. Apollo 1 output channels 1-8 into summing input channel 1-8 of Dbox. Apollo 1 main L&R going to main analog input L&R of Dbox. Spid out to DAW input of Dbox. I have both ADAT of both Apollos connected by optical wire. Also have port 2 of Apollo 1 into port 1 of Apollo 2 connected by Firewire.  Let me know. Hope I got it right. Thanks for responding.

  • When click the email icon on my iphone, it opens on one email only.  I can not go to the next or previous email, a different email or anything.  It only gives me the option to move that email!  How can I stop this.  Its been working perfectly well before!

    When click the email icon on my iphone, it opens on one email only.  I can not go to the next or previous email, a different email or anything.  It only gives me the option to move that email!  How can I stop this.  Its been working perfectly well before!

    Now as you may know there is some icons at the bottom of the mail app, at the top left conner you should have the inbox button and on the upper right conner you should have two arrows to shift between emails. If any of those options works try :
    Settings>General>Reset>Reset all Settings
    If that does not work try to re add the account
    Last but not least, restore as new.
    Hope that helps.

  • Query can't include an "ORDER BY" clause when having column heading sorting

    I'm getting the following error when I try to include "ORDER BY" in my sql statement :
    "Your query can't include an "ORDER BY" clause when having column heading sorting enabled"
    I have used other sql statements with "ORDER BY" but this is the first time I have come across this and I don't understand why it's going wrong. Does anyone have a suggestion as to how I could fix it? Here is one of the sql statements which I have tried which is giving me the error:
    select "ID_NUMBER",
    "PROJECT_NAME",
    "PROJECT_TYPE",
    "OWNER",
    "PRIORITY",
    "STATUS",
    "END_DATE",
    "COMMENTS"
    from "PROJECT"
    WHERE "STATUS" != 'Completed' AND "STATUS" != 'Cancelled'
    ORDER BY "END_DATE"
    Regards,
    Ed.

    You must deselect column heading sorting that is in the page "Report Attributes" .This is a check box placed on the same line of the element of the report.
    bye

  • Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.

    hi all
    i have a table that name is:
    TiketsHeader 
    but i used this code
    SELECT TicketsHeaderId, Active, TH.PersonRef,P.Fname + ' ' + P.Lname AS NF, Serial, TicketsCnt, StartSerial, EndSerial, KindDate, StratDate, EndDate,
    MonthsRef1,(SELECT * FROM dbo.Months M WHERE M.MonthsId= MonthsRef1 ) AS MonthsName1 , MonthsRef2, MonthsRef3, WeekDaysRef,
    PoolTimesRef, TH.Descreption
    FROM dbo.TiketsHeader TH
    INNER JOIN Person P ON P.PersonId= TH.PersonRef
    i see this error:
    Msg 116, Level 16, State 1, Line 2
    Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.
    how to solve it
    please help me
    Name of Allah, Most Gracious, Most Merciful and He created the human

    SELECT TicketsHeaderId, Active, TH.PersonRef,P.Fname + ' ' + P.Lname AS NF, Serial, TicketsCnt, StartSerial, EndSerial, KindDate, StratDate, EndDate,
    MonthsRef1,(SELECT * FROM dbo.Months M WHERE M.MonthsId= MonthsRef1 ) AS MonthsName1 , MonthsRef2, MonthsRef3, WeekDaysRef,
    PoolTimesRef, TH.Descreption
    FROM dbo.TiketsHeader TH
    INNER JOIN Person P ON P.PersonId= TH.PersonRef
    A Sub query like this can only return one column, not serveral like here with the star *. Replace the star by one column Name that you want to query.
    Olaf Helper
    [ Blog] [ Xing] [ MVP]

  • Msg 116, Level 16, State 1, Line 6 Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.

    Hello,
    Can anyone help me?
    select year(po.rdata) as 'Ano', 
    sum(etotal) as 'Valorp' ,
    (select year(fo.data),Sum(etotal) 
    FROM fo (nolock) 
    where  not exists ( select 1 from pl (nolock) where pl.adoc = fo.adoc and pl.cm = fo.doccode ) 
    group by year(fo.data))as 'Valorap'   
    from po 
    group by year(po.rdata)
    order by year(po.rdata)
    Error 
    Msg 116, Level 16, State 1, Line 6
    Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.
    Consultora

    Hi Prashanth,
    select year(po.rdata) as 'Ano',
    sum(etotal) as 'Valorp' ,
    (select Sum(etotal)
    FROM fo (nolock)
    where not exists ( select 1 from pl (nolock) where pl.adoc = fo.adoc and pl.cm = fo.doccode )
    group by year(fo.data))as 'Valorap'
    from po(nolock)
    group by year(po.rdata)
    order by year(po.rdata)
    Gives me the error: 
    Msg 512, Level 16, State 1, Line 1
    Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
    Thanks
    Consultora

  • Only period 012 can be posted in the repeat run

    Hi Experts,
    And when i am doing  AFAB Click on Repeat Run Excute inTest Run
    System give another error:
    Only period 012 can be posted in the repeat run
        Message no. AAPO516
    Diagnosis
        You want to carry out a repeat depreciation posting run in period 001.
        However, the last posting run was for period 012.
    System Response
        The repeat run cannot be carried out. Processing is cancelled.
    Procedure
        Start the repeat run again using period 012.
    Waiting for reply.
    In advance thanks
    Regards,
    Jemes

    Hi,
    Repeat run is possible only in the last executed period of relevant year which is not closed in AA and GL.
    Best Regards,
    Madhu

  • I just got my new iPad and I can't find the hotspot option in settings ? Plz guid me on how to turn my hotspot on in that case if I can't even see the option !!

    I just got my new iPad and I can't find the hotspot option in settings ? Plz guid me on how to turn my hotspot on in that case if I can't even see the option !!

    You can download a complete iPad User Guide here: http://manuals.info.apple.com/en/ipad_user_guide.pdf
    Also, Good Instructions http://www.tcgeeks.com/how-to-use-ipad-2/
    Apple - iPad - Guided Tours
    http://www.apple.com/ipad/videos/
    Watch the videos see all the amazing iPad apps in action. Learn how to use FaceTime, Mail, Safari, Videos, Maps, iBooks, App Store, and more.
    How to - Articles & User Guides & Tutorials
    http://www.iphone-mac.com/index.php/Index/howto/id/4/type/select
    iPad How-Tos  http://ipod.about.com/lr/ipad_how-tos/903396/1/
    You can download this guide to your iPad.
    iPad User Guide for iOS 5
    http://itunes.apple.com/us/book/ipad-user-guide-for-ios-5/id470308101?mt=11
     Cheers, Tom

  • I just bought a ipod touch. I am unable to use it because itunes tells me I have no internet connection (unknown error 306). I have tried all the suggestions I can find, including checking the firewall, the no proxy server is checked, resetting cache on i

    I just bought a ipod touch. I am unable to use it because itunes tells me I have no internet connection (unknown error 306). I have tried all the suggestions I can find, including checking the firewall, the no proxy server is checked, resetting cache on itunes, I even scanned the computer with Registry Easy but nothing worked.  I use Mozilla Firefox and have a PC with Windows 7. Obviously, buying a ipod and being unable to use it for 3 days (and counting) because I am unable to register it, is pretty frustrating. Can anyone help?

    Did you try all of this:
    iTunes Store loads partially or returns "Error 306" or "Error 10054"
    Proxies, parental control settings and software, security or filtering software, or a bad iTunes Store cache can cause this.
    To address proxies, Remove Internet Options proxy settings and connect to the Internet without a proxy.
    To reset iTunes Store cache:
    In iTunes, choose iTunes > Preferences (Mac) or Edit > Preferences (PC).
    Click the Advanced tab.
    Click the "Reset cache" button.
    Click OK and see if the issue is resolved.
    Adjust Parental Controls in iTunes:
    Open iTunes.
    Access iTunes preferences:
    On a Mac: From the iTunes menu, choose Preferences.
    On a Windows PC: From the Edit menu, choose Preferences.
    Click the Parental Controls tab.
    Remove restrictions on Parental Controls.
    For more information on parental controls or content filtering software, see iTunes 10.5 for Windows: May see performance issues and blank iTunes Store.
    For more information on other security software, see iTunes: Troubleshooting security software issues.

Maybe you are looking for

  • Safari stopped working after completed MAcosxupdcombo 10.7.4

    Hello all, Sorry to bother and I want to thank you in advance for any help you can offer. After completing an update and the computer restarted, I tried to open safari and received the report info below. Please help me to get safari up and running. S

  • How to call servlets in sunone webserver

    hi, I am using sunone web server , I deployed but how to call servlets in sunone webserver any one tell me bye

  • Recommended tool for technical illustrations to be embedded in FrameMaker document?

    I'm new to Framemaker and don't know, if this is the right tool for me. I have written a technical document of about 500 pages using MS-Word. Now I want to figure out, if FrameMaker would be a good alternative. I think it could be. But one of my need

  • Essbase 11.1.2.2 in IBM AIX 6.1 (ERROR: JNI: Failure running chmod in setNa

    Hi, I am installing Essbase 11.1.2.2 in IBM AIX 6.1 server, during installation getting below error, please provide any inputs. ERROR: JNI: Failure running chmod in setNativeFileAttributes(/ngs/app/gbiessd/Oracle/Middleware/EPMSystem11R1/../oracle_co

  • Windows 2008 R2 server

    1. Registry editor: HKEY_local_Machine\Software\Microsoft\WBEM\Scripting DefaultNameSpace path is indicated ok 2. WMI Control properties \Advanced Default name space for scripting is ­grayed and path is not accessible. 3. WMI control properties\Gener