Select MAX(BUDAT) from ztab (custom table) where... NOT work!

We use the following statement where BUDAT is one of the fields in our custom table ztab:
Select MAX(BUDAT) from ztab (custom table) where...
When activating the above code, get the following error:
"Unknown column name "MAX(BUDAT)". not determined until runtime, you cannot specify a field list."
How to resolve this problem to get a max value of the field BUDAT in custom table ztab (it's not an internal table)?
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Apr 10, 2008 3:56 PM

HI,
Tyr having a space after and before BUDAT.
( BUDAT ).
Hope it helps,
Shreekant

Similar Messages

  • Giving Error When Selecting From a Custom Table

    There is a custom report 'Z*'  which archives data.
    In this report, while selecting data(needs to be archived) from a custom table 'Z*_T', giving runtime error in Production Server.
    The select statement is written below :
    *data izX like z_t occurs 1000 with header line._
    *select * from z*t into table i_zX.*_
    How can I change the select statement so that it will work properly?

    Sas..
    From your example code it appears you are trying to use a wild card for both your dbtable and the internal table.
    To do this, you will lilkely need to use a Field Symbol for the target internal table and your FROM will need to be a varible
    FROM (dbtabname)
    The ABAP Helps gives this example for the Select Table
    DATA  TABNAME(10).
    DATA: BEGIN OF WA,
            ID   LIKE SCUSTOM-ID,
            NAME LIKE SCUSTOM-NAME,
            REST(134),
          END OF WA.
    TABNAME = 'SCUSTOM'.
    SELECT * INTO WA FROM (TABNAME).
      WRITE: / WA-ID, WA-NAME.
    ENDSELECT.

  • Select max date from a table with multiple records

    I need help writing an SQL to select max date from a table with multiple records.
    Here's the scenario. There are multiple SA_IDs repeated with various EFFDT (dates). I want to retrieve the most recent effective date so that the SA_ID is unique. Looks simple, but I can't figure this out. Please help.
    SA_ID CHAR_TYPE_CD EFFDT CHAR_VAL
    0000651005 BASE 15-AUG-07 YES
    0000651005 BASE 13-NOV-09 NO
    0010973671 BASE 20-MAR-08 YES
    0010973671 BASE 18-JUN-10 NO

    Hi,
    Welcome to the forum!
    Whenever you have a question, post a little sample data in a form that people can use to re-create the problem and test their ideas.
    For example:
    CREATE TABLE     table_x
    (     sa_id          NUMBER (10)
    ,     char_type     VARCHAR2 (10)
    ,     effdt          DATE
    ,     char_val     VARCHAR2 (10)
    INSERT INTO table_x (sa_id,  char_type, effdt,                          char_val)
         VALUES     (0000651005, 'BASE',    TO_DATE ('15-AUG-2007', 'DD-MON-YYYY'), 'YES');
    INSERT INTO table_x (sa_id,  char_type, effdt,                          char_val)
         VALUES     (0000651005, 'BASE',    TO_DATE ('13-NOV-2009', 'DD-MON-YYYY'), 'NO');
    INSERT INTO table_x (sa_id,  char_type, effdt,                          char_val)
         VALUES     (0010973671, 'BASE',    TO_DATE ('20-MAR-2008', 'DD-MON-YYYY'), 'YES');
    INSERT INTO table_x (sa_id,  char_type, effdt,                          char_val)
         VALUES     (0010973671, 'BASE',    TO_DATE ('18-JUN-2010', 'DD-MON-YYYY'), 'NO');
    COMMIT;Also, post the results that you want from that data. I'm not certain, but I think you want these results:
    `    SA_ID LAST_EFFD
        651005 13-NOV-09
      10973671 18-JUN-10That is, the latest effdt for each distinct sa_id.
    Here's how to get those results:
    SELECT    sa_id
    ,         MAX (effdt)    AS last_effdt
    FROM      table_x
    GROUP BY  sa_id
    ;

  • How to select LAST line from a SAP table?

    Hi developers,
    I need to select the last line from a SAP table, NOT from an internal table.
    Something like
    SELECT SINGLE LAST FROM pa00169..
    any help is more than welcome.

    Javier,
    Based on this statement from you:
    "i created a Z table, its a config table that stores some bussines rules, and an id counter, so in order to update that counter i need the last line of the ztable."
    I have one additional solution which is the "text box" approach IF the 'id counter' mentioned above is a numeric data type.
    If so, use an SQL function to get the highest value of ID_COUNTER.
    Then simply add one to it to produce a new, unique, higher-order primary key.
    See below:
    data: l_id_counter like ztable-id_counter.
    data: new_id_counter like ztable-id_counter.
    select max( ID_COUNTER ) from ztable into l_id_counter.
    new_id_counter = l_i_counter + 1.
    Now new_id_counter will be the unique, primary key IF this is the only field in ZTABLE's primary key.
    This will also GUARANTEE that your new record is built correctly.

  • Randomly selecting some rows from the database table

    Hi can some one help me in selecting some rows from a database table which has around 90,000 rows.
    Thanks.

    One thing you might try is the "sample" clause if you have 8i which is supposed to return a random percentage of the table. Say for example, you have a sequence number on your table as the pkey. Then you might try:
    select * from <table_name> where pkey in(select pkey from <table_name> sample(10));
    This should give you a random 10 percent of the rows in the table but I tried this once and the results seemed unpredictable. For example it returned a different number of rows each time even though the number of rows in the table didn't change.
    Hope this works for you.

  • How to select alternate entries from the database table

    Hi Experts,
    can u help me, how to select alternate entries from the database table.
    Thanks

    As there is no concept of sequence (unless there is a field specifically included for the purpose), there is no meaning to "alternate" records.
    What table do you have in mind, what data does it hold, and why do you want alternate records?
    matt

  • Illegal selection by InfoObject from outer join table

    Hi all,
    in any infoset with left-outer-join, when i want to select any field (infoobject) to get exlude conditions i got these errors:
    illegal selection by InfoObject from outer join table.
    error reading the data of infoprovider '*'.
    thanks in advance .
    HS

    Hi Dorota,
    Choudhary S was right.
    İ have notified the SAP about this issue..they wrote me below note :
    As SAP tables have no concept for NULL, we
    have to restrict this condition to not allow excluding condition to be
    used any more. But alternatively, you could use including to replace it.
    Please check my last reply to see the detailed reason for it, and
    this explaination is from our development colleagues.
    For this note 1435772, you could also see why this error message
    arises.
    So, they said it is not possible in case of left outer join after those patches.
    i just used  include to replace that exluding condition.it takes little time but the problem is solving.
    Thanks
    HS

  • How to force BI Server to pick from the Agg table and not the Fact table?

    Hi All,
    I have 3 tables as the Sources in the Key measures. 2 are fact tables and the other one is the agg table.
    E.g.
    Fact 1 at A,B,C,D and E level
    Fact 2 at A,B,C level
    Agg at A,B,C level which contains the measures from the Fact1 and Fact2
    So when I select the measures from the Agg which are coming from Fact1 the Agg table get fired and when I select measures from Agg which are coming from Fact2, the Fact2 table gets fired in the SQL Query.
    Now my question here is there anyway to tell BI Server that when I select Fact2 measures fire the Agg table and not the Fact2 table. The reason being the Agg and Fact2 tables are at the same level.
    But I need to keep the Agg table as it is one level higher than the Fact1 tables.
    Any pointers would be helpful.

    hi,
    you explain us your situation really good.but you forgot to tell us the most import,the measures in aggregate table and the aggregated dimensions.
    meaning,you have 7 measures aggregated in some levels of your dimensions tables?if yes,there is no possibility Bi goes anywhere else..(by choosing only these measures and the defined levels at your dimensions..)
    One more thing,if you choose a combination of your 2 fact data sources,bi goes?where???
    hope i helped...
    http://greekoraclebi.blogspot.com/

  • Custom Table Entry not in Sync between Different Environment

    Hi All,
    we have different environment like Dev System, Quality system, performance testing system etc... these are all environment customs table entry not in syn .. Table entry should be syn. How to make it syn all the entry between all environment without do any manual work. Kindly help on this.
    Thanks

    Hello Mohammed,
    It depends on what type of tables you are referring to. If you have a table of type 'Customizing', you have to transport your table entries across different environments and they will be in Sync.
    If you are referring to tables of type 'Master Data', they have to be maintained in all environments.
    Table of type 'Transaction Data' by default have different records based on your day to day transactions.
    You cannot have all custom tables with same data in all environments. Hope this helps.
    Rgds,
    Vijay.

  • My speakers from my iPhone 4S is not working I'm clicking on the buttons on the side nd the volume is not even showing getting louder or lower but when I plug in my ear phones I can hear it juss happen out of no where what sould I do ?

    My speakers from my iPhone 4S is not working I'm clicking on the buttons on the side nd the volume is not even showing getting louder or lower but when I plug in my ear phones I can hear it juss happen out of no where what sould I do ?

    Your iPhone charging port may have a minor short, causing iPhone to falsely sense it is connected to a dock turning off its speaker. Clean iPhone charging port with a clean dry toothbrush.

  • ADCS Remove child table is not working

    Hi
    The AD out-of-box adapter ADCS Remove from child table is not working correctly.
    when i remove data from child table the task status shows completed, but the description inside the task shows that the GROUP HAS BEEN REMOVED ALREADY FROM TARGET.
    But on checking the AD I found the groups were not removed actually.
    In the log i found this error
    Running Remove User From Group
    DEBUG,03 Nov 2009 10:21:06,099,[OIMCP.ADCS],tcUtilADTasks::removeUserFromGroup() Enter
    DEBUG,03 Nov 2009 10:21:06,099,[OIMCP.ADCS],tcUtilADTasks::getLookupCodeValue() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcUtilADTasks::getLookupCodeValue() Exit
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcUtilADTasks::getObjectByObjectGUID() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::search() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::getPath() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::getPath() Exit
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::connectToAvailableAD() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForDirContext() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForDirContext() Exit
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForLDAPContext() Enter
    DEBUG,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForLDAPContext() Exit
    INFO,03 Nov 2009 10:21:06,115,[OIMCP.ADCS],SSL option is not selected in ITResource
    DEBUG,03 Nov 2009 10:21:06,131,[OIMCP.ADCS],tcADUtilLDAPController::connectToAvailableAD() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::disconnect() Enter
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::disconnect() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::search() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcUtilADTasks::getObjectByObjectGUID() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::getPath() Enter
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::getPath() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::connectToAvailableAD() Enter
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForDirContext() Enter
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForDirContext() Exit
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForLDAPContext() Enter
    DEBUG,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],tcADUtilLDAPController::hashTableEnvForLDAPContext() Exit
    INFO,03 Nov 2009 10:21:06,334,[OIMCP.ADCS],SSL option is not selected in ITResource
    DEBUG,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],tcADUtilLDAPController::connectToAvailableAD() Exit
    DEBUG,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],tcADUtilLDAPController::modifyAttributes() Enter
    *ERROR,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],The error occured in tcADUtilLDAPController::modifyAttributes():null*
    DEBUG,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],tcADUtilLDAPController::disconnect() Enter
    DEBUG,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],tcADUtilLDAPController::disconnect() Exit
    DEBUG,03 Nov 2009 10:21:06,349,[OIMCP.ADCS],tcUtilADTasks::removeUserFromGroup() Exit
    Any thoughts would be grateful
    TIA,
    Manoj

    Hi Manoj,
    The error message below is performed when the connector tried to remove the user from a user group removeUserFromGroup() (ADCS Remove User From Group), so the user group will not be removed. To delete a group, you have to run the delete group task of AD Group process.
    When the user has already been removed from the group, the connectors shows null to the tcADUtilLDAPController::modifyAttributes():null
    Renato.

  • BIP report security from Dashboard to Publisher is not working

    Hi ,
    I created a BIP report(.xdo) and placed it on Dashboard as a link . As admin , I can see the report . As a user , I am able to get into publisher but not able to see the report . Iam getting the below error message .
    Error : Unauthorized Access: please contact the administrator.
    I suspect that security model from Dashboard through BIP is not working . I tried searching the online resources but couldnt find right help .
    Iam a newbie for BIP , I followed the regular BIP guides , configured eveything as per the docs and things work as admin . But I want to test the security as user .
    Where Iam doing wrong , Any ideas please help .
    Thanks
    Karthik

    Hello Vijay ,
    I have grant permissions to the user and the report in BI webcatalog and also in BIP under admin tab I have addes the role which the user belongs to and also the shared folder . Still the problem exists.
    My BI presentation servcies security is working . My user security is also working , all that I need is the user should be able to see the report when he clicks on BIP link placed in dashboard.

  • Command Link in ADF table is not working/ PPR event not getting fired

    Hi All,
    I am having ADF Table, in that one column is with command link if click on command link, it is not navigating to corresponding page or method of a bean. If i give same command link out of the table it working fine, this issue i am facing is in IE9.
    if i use IE in compatibility mode the links works fine, even in IE8 version also.
    Browser: IE 9
    Jdev version: 11.1.1.5.0
    I tried all possible things, but nothing workout for me.
    showPopupBehavior not working in IE9 for af:table buttons (jdev11.1.1.5.0)
    Partial page rendering not working in ie9
    Command Link in ADF table is not working
    Thnks

    Hi,
    please file a bug if you have a customer support contract and provide a testcase
    Frank

  • Update to 10.6.8 and HP F2100 and D2400 Printers stopped working. Restored 10.6.7 and printers from Install CD's but not working,  Same with scanner

    Help....
    Updated to 10.6.8 and HP F2100 and D2400 Printers stopped working.
    Restored 10.6.7 and printers from Install CD's but not working.
    Same with F2100 scanner
    Am I glad I kept Windows desktop as without it I would be scre**ed now
    What is going on with this latest update as its like a return to Windows with things crashing or hanging up every few minutes????
    On a MacBook Air that has not been updated everything still works so what has 10.6.8 done and why won't the restore to 10.6.7 work?
    Steve

    None of those things you mentioned were what I suggested.
    I'm guessing the "ctrl click in printer preferences" means you Reset the Printing System?
    If so, that is what I would have suggested if deleting it by selecting the ( - ) button and then adding it with the ( + ) button.
    But, if HP has a fix, it likely needs to update its drivers.

  • Ukelele generated custom keyboard layouts not working in Lion?

    I asked this question in the stackexchange site a few days ago.  Nothing I've tried has worked so far, except for creating a new account.  Because a fresh account works, it's got to be something with my preferences, right?
    http://apple.stackexchange.com/questions/21691/ukelele-generated-custom-keyboard -layouts-not-working-in-lion
    Here's the question from above:
    I created a custom keyboard layout with Ukelele (http://scripts.sil.org/ukelele) in Snow Leopard (idea is to generate scandinavian letters with Alt-key, otherwise have a pretty much standard U.S. layout). After the upgrade, the old installed (to ~/Library/Keyboard Layouts) layout wasn't working.
    Ukelele seems to work OK in Lion, but whether I put the generated keylayout in a bundle or single file, or save it "/Library/Keyboard Layouts" or "~/Library/Keyboard Layouts" doesn't seem to matter.
    Help?
    EDIT:
    @Sergio, I cannot choose the layout in Input Sources. One keylayout file I tried:http://semeai.org/~sjl/us-scands.keylayout
    [EDIT: Removed unrelated stuff]
    UPDATE 2011/08/15:
    @Tom:
    Copied your keylayout (it naturally ended up in my Junk folder):
    midgard (01:55) >ls -l ~/Library/Keyboard\ Layouts/MongolianQWERTY.keylayout-rw-r--r--@ 1 sjl  staff  44536 Mar 13  2008 /Users/sjl/Library/Keyboard Layouts/MongolianQWERTY.keylayout
    Logged out, logged in, isn't showing in Input sources (I'm looking very closely between "Maori" and "Myanmar - QWERTY").
    I've also uninstalled bunch of software and plugins giving suspicious messages to system.log, but hasn't helped.
    UPDATE 2011/08/16:
    I created a test account, and lo, the layout works perfectly for it. Also the bug in preferences doesn't show for that account. When trying this on my own account, there are no errors in Console logs with the suggested keywords (I can't seem to locate console.log file, though).
    UPDATE 2011/08/16 later:
    Nuking Library/Caches (and relogging) didn't help.
    UPDATE 2011/08/17:
    I did
    % find Library -name "*.plist" -exec mv {} {}.renamed \;
    and restarted, but it didn't help. I restored the situation with
    % for file in `find Library -name "*.plist.renamed"`; \  do mv "$file" "${file//.renamed/}"; done
    addendum: I also went through all the .plist files with plutil -s as described inhttp://www.askdavetaylor.com/can_i_check_my_plist_files_in_mac_os_x_for_problems .html. There was some brokennes, but in very unrelated applications.

    Tom,
    I think I love you.
    That absolutely did it! Thanks so much!
    If you'll answer with the same link in the stackexchange site, I'll mark the answer as correct, so you'll get the rep there.
    Thanks,
    Sami

Maybe you are looking for

  • Report Generation in 8.6

    Hello Friends    I m going to study the Report Generation Toolkit in Labview 8.6.I need any simple example vi to study for this toolkit.Please suggest ur Vis

  • ADFC-10001 Error while creating user in oim

    Hi All, I am getting ADFC-10001: cannot instantiate class 'oracle.iam.identitytaskflow.backing.taskflows.createuser.createuserview' error while creating user. ADF_FACES-60097:For more information, please see the server's error log for an entry beginn

  • Business Catalyst & Adsense

    Anyone her use Adsense with BC sites? Any tips on how to go about it with modules, tags, apps? Thanks

  • Masters missing from thumbnails

    After scanning and editing in Preview, all I can find are the thumbnails, and no master. Where are they?!!

  • I can't see the screen in the sun

    I've searched for an answer, but can't find one. I have a 8320 and I use the theme that came with the phone. I can not see anything on the screen when there is a lot of light (i.e. outside).  Is there a theme or some kind of setting I can use to help