Hxc_timestore_deposit.create_time_entry creating negative values

Hi,
I am trying to create time entry through back end using API (hxc_timestore_deposit.create_time_entry) as
declare
l_time_building_block_id hxc_time_building_blocks.time_building_block_id%TYPE;
l_tbl_attributes_info hxc_self_service_time_deposit.app_attributes_info ;
l_return_status varchar2(30);
l_tbl_timecard_info hxc_self_service_time_deposit.timecard_info ; --hxc_block_table_type;
begin
hxc_timestore_deposit.create_time_entry (
p_start_time=> fnd_date.canonical_to_date('2009/09/02 09:00:00'),
p_stop_time=> fnd_date.canonical_to_date('2009/09/02 17:00:00'),
p_resource_id=> 7427, --9389, -- Identifies a person on our DB, REPLACE WITH YOUR IDs
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_time_building_block_id=> l_time_building_block_id
l_return_status := fnd_api.g_ret_sts_success;
DBMS_OUTPUT.PUT_LINE('TESTING of hxc_timestore_deposit');
DBMS_OUTPUT.PUT_LINE('return_status : ' ||l_return_status);
DBMS_OUTPUT.PUT_LINE(' l_time_building_block_id :- '||l_time_building_block_id);
end;
Above code is creating negative values for time_building_block_id.
Can anyone pls help me.
Thanks
Rutuja

Hi,
I have developed one more script to create a time card.
It is also generating negative values.
Can anyone knows the problem
Pls help me regarding the same.
Thanks in advance.
Rutuja
DECLARE
-- Constant declarations
-- This is the appl_id for OTL, do not change
c_otl_appl_id CONSTANT NUMBER (3) := 809;
c_proj_attr1 CONSTANT VARCHAR2 (7) := 'Task_Id';
c_proj_attr2 CONSTANT VARCHAR2 (10) := 'Project_Id';
c_proj_attr3 CONSTANT VARCHAR2 (16) := 'Expenditure_Type';
c_proj_attr4 CONSTANT VARCHAR2 (19) := 'Expenditure_Comment';
c_proj_attr5 CONSTANT VARCHAR2 (23) := 'SYSTEM_LINKAGE_FUNCTION';
v_msg_info                VARCHAR2(20000);
x_status_msg                VARCHAR2(20000);
vx_msg_index_out           NUMBER;
-- Variable declarations
-- declare the PL/SQL Table that will hold the complete timecard (all the BBs)
l_tbl_timecard_info hxc_self_service_time_deposit.timecard_info;
-- declare the PL/SQL Table that will hold all the attributes
l_tbl_attributes_info hxc_self_service_time_deposit.app_attributes_info;
-- declare the PL/SQL Table that will hold the messages returned by the API
l_tbl_messages hxc_self_service_time_deposit.message_table;
-- person ID that this TC belongs to, Replace with your own
l_person_id per_all_people_f.person_id%TYPE := 2638;--9389;
-- Replace with your own IDs
l_task_id VARCHAR2 (4) := '2011';--HOLIDAY--'221';
-- (l_project_id is NOT the same as task id, they just happen to have the
-- same ID on our database)
l_project_id VARCHAR2 (3) := '803';--'221';
-- Replace with your own values
l_expenditure_type VARCHAR2 (15) := 'Professional';
l_ot_expenditure_type VARCHAR2 (15) := 'Overtime';
l_system_linkage_id VARCHAR2 (15) := 'ST';
l_ot_system_linkage_id VARCHAR2 (15) := 'OT';
-- Will hold TC_ID, returned by the deposit process
l_new_timecard_id NUMBER;
-- Will hold TC ovn, returned by the deposit process
l_new_timecard_ovn NUMBER;
l_message fnd_new_messages.message_text%TYPE;
l_start_time DATE := fnd_date.canonical_to_date('2009/09/16 00:00:00');
l_stop_time DATE := fnd_date.canonical_to_date('2009/09/22 23:59:59');
l_tc_bb_id hxc_time_building_blocks.time_building_block_id%TYPE;
l_day_bb_id hxc_time_building_blocks.time_building_block_id%TYPE;
l_detail_bb_id hxc_time_building_blocks.time_building_block_id%TYPE;
l_time_attribute_id hxc_time_attributes.time_attribute_id%TYPE;
BEGIN
-- First initialize your session, this needs to be done for internal reasons so
-- the TimeStore knows who is trying to deposit the information. When you log
-- into SS, the same is done for you by the framework, here however we have to do
-- it manually.
dbms_application_info.set_client_info(206);
FND_GLOBAL.APPS_INITIALIZE(1781,51681,809 );-- This is the appl_id for OTL, do not change
-- PART 1: POPULATE TABLES --
-- First populate the timecard PL/SQL table:
-- Start with the TIMECARD BB
hxc_timestore_deposit.create_timecard_bb(
p_start_time=> l_start_time,
p_stop_time=> l_stop_time,
p_resource_id=> l_person_id,
p_comment_text=> 'Created using API: Weekly Project TC',
p_app_blocks=> l_tbl_timecard_info,
p_time_building_block_id=> l_tc_bb_id);
DBMS_OUTPUT.PUT_LINE(' l_tc_bb_id :- '||l_tc_bb_id);
FOR j IN 1..FND_MSG_PUB.Count_Msg
     LOOP
FND_MSG_PUB.GET( p_msg_index => -1
,p_encoded => 'F'
,p_data => v_msg_info
,p_msg_index_out => vx_msg_index_out);
x_status_msg := x_status_msg || v_msg_info;
     END LOOP;                         
DBMS_OUTPUT.PUT_LINE(' 1st API STATUS :- '||x_status_msg);
COMMIT;                         
-- Now we create the DAY BB, 7 in total, and since they are all the same we
-- will loop 7 times
FOR i_day IN 0 .. 6
LOOP
hxc_timestore_deposit.create_day_bb (
p_day => TRUNC (l_start_time)+ i_day,
p_parent_building_block_id=> l_tc_bb_id, -- returned by create_timecard_bb
p_comment_text=> 'Created using API',
p_app_blocks=> l_tbl_timecard_info,
p_time_building_block_id=> l_day_bb_id);
DBMS_OUTPUT.PUT_LINE(' l_day_bb_id :- '||l_day_bb_id);
v_msg_info := NULL;
x_status_msg := NULL;
vx_msg_index_out := NULL;
FOR j IN 1..FND_MSG_PUB.Count_Msg
     LOOP
FND_MSG_PUB.GET( p_msg_index => -1
,p_encoded => 'F'
,p_data => v_msg_info
,p_msg_index_out => vx_msg_index_out);
x_status_msg := x_status_msg|| v_msg_info;
     END LOOP;                         
                         DBMS_OUTPUT.PUT_LINE(' 2nd API STATUS :- '||x_status_msg);
-- The next call would also work but we choose to use the first one
-- since we know the TIMECARD's Id. If you do not know the ID you should
-- use this next call commented out here.
/* hxc_timestore_deposit.create_day_bb (
p_day => TRUNC (l_start_time)
+ i_day,
p_resource_id=> l_person_id,
p_comment_text=> 'Created using API',
p_app_blocks=> l_tbl_timecard_info,
p_time_building_block_id=> l_day_bb_id
-- We can attache the DETAIL BB for every DAY BB that represents 'normal'
-- work hours as well here as they are all the same
-- We only need to do this for weekdays though
IF i_day < 5
THEN
hxc_timestore_deposit.create_detail_bb (
p_type=> 'MEASURE',
p_measure=> 8,
p_parent_building_block_id=> l_day_bb_id,
p_comment_text=> 'Created using API: NT',
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_time_building_block_id=> l_detail_bb_id
DBMS_OUTPUT.PUT_LINE(' l_detail_bb_id :- '||l_detail_bb_id);
v_msg_info := NULL;
x_status_msg := NULL;
vx_msg_index_out := NULL;
FOR j IN 1..FND_MSG_PUB.Count_Msg
     LOOP
FND_MSG_PUB.GET( p_msg_index => -1
,p_encoded => 'F'
,p_data => v_msg_info
,p_msg_index_out => vx_msg_index_out);
x_status_msg := x_status_msg|| v_msg_info;
     END LOOP;                         
                         DBMS_OUTPUT.PUT_LINE(' 3nd API STATUS :- '||x_status_msg);
-- The next call would also work but we choose to use the first one
-- since we know the DAY's Id. If you do not know the ID you should
-- use this next call commented out here. In fact we use it ourselves
-- later to add the overtime.
/* hxc_timestore_deposit.create_time_entry (
p_measure=> 8,
p_day => TRUNC (l_start_time)
+ i_day,
p_resource_id=> l_person_id,
p_comment_text=> 'Created using API: NT',
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_time_building_block_id=> l_detail_bb_id
-- We can also attach the attributes to every BB that represent
-- 'normal' work hours
-- Attribute1
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr1,
p_attribute_value=> l_task_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute2
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr2,
p_attribute_value=> l_project_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute3
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr3,
p_attribute_value=> l_expenditure_type,
p_app_attributes=> l_tbl_attributes_info
-- Attribute4
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr4,
p_attribute_value=> 'Expenditure Comment created by API',
p_app_attributes=> l_tbl_attributes_info
-- Attribute5
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr5,
p_attribute_value=> l_system_linkage_id,
p_app_attributes=> l_tbl_attributes_info
END IF; -- Only for weekdays
END LOOP; -- End creating normal working days + time
-- And now we add the Overtime to Tuesday and Wednesday
-- We have to use create_time_entry here because we do not have the ID
-- for the Wednesday TBB anymore, using create_time_entry we do not need it
-- Tuesday
hxc_timestore_deposit.create_time_entry (
p_measure=> 1,
p_day => TRUNC (l_start_time)+ 1,
p_resource_id=> l_person_id,
p_comment_text=> 'Created using API: OT',
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_time_building_block_id=> l_detail_bb_id
-- Attribute1
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr1,
p_attribute_value=> l_task_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute2
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr2,
p_attribute_value=> l_project_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute3
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr3,
p_attribute_value=> l_ot_expenditure_type,
p_app_attributes=> l_tbl_attributes_info
-- Attribute4
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr4,
p_attribute_value=> 'Expenditure Comment created by API',
p_app_attributes=> l_tbl_attributes_info
-- Attribute5
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr5,
p_attribute_value=> l_ot_system_linkage_id,
p_app_attributes=> l_tbl_attributes_info
-- Wednesday
hxc_timestore_deposit.create_time_entry (
p_measure=> 2,
p_day => TRUNC (l_start_time)
+ 2,
p_resource_id=> l_person_id,
p_comment_text=> 'Created using API: OT',
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_time_building_block_id=> l_detail_bb_id
-- Attribute1
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr1,
p_attribute_value=> l_task_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute2
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr2,
p_attribute_value=> l_project_id,
p_app_attributes=> l_tbl_attributes_info
-- Attribute3
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr3,
p_attribute_value=> l_ot_expenditure_type,
p_app_attributes=> l_tbl_attributes_info
-- Attribute4
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr4,
p_attribute_value=> 'Expenditure Comment created by API',
p_app_attributes=> l_tbl_attributes_info
-- Attribute5
hxc_timestore_deposit.create_attribute (
p_building_block_id=> l_detail_bb_id,
p_attribute_name=> c_proj_attr5,
p_attribute_value=> l_ot_system_linkage_id,
p_app_attributes=> l_tbl_attributes_info
-- END OF PART 1: POPULATE TABLES --
-- PART 2: DEPOSIT TIMECARD --
-- Now we call the deposit process, passing in the PL/SQL tables we just
-- created and populated
hxc_timestore_deposit.execute_deposit_process (
p_validate=> FALSE,
p_app_blocks=> l_tbl_timecard_info,
p_app_attributes=> l_tbl_attributes_info,
p_messages=> l_tbl_messages,
p_mode=> 'SUBMIT',
p_deposit_process=> 'OTL Deposit Process',
p_timecard_id=> l_new_timecard_id,
p_timecard_ovn=> l_new_timecard_ovn
-- END OF PART 2: DEPOSIT TIMECARD --
END;
COMMIT;

Similar Messages

  • FileInputStream.read returning negative values

    I'm trying to read binary data from a file and convert it to decimal. If I use a hex editor, through one section, I'll see the values as they actually are. Using read() on a FileInputStream object seems to randomly create negative values which are sometimes correct if I use Math.abs(), and sometimes theyre not. I don't have a clue what's going on and it's getting frustrating, as FileInputStream.read() supposedly returns an integer between 0 ane 255, which is what I'm expecting.
    Thanks for the help!

    Are you doing something like this...
    byte value = in.read();
    int useIt = value;If the value is being stored in a byte and then cast to an int, the sign bit will be extended and it will become negative. This is because a java byte is actualy +/- 127.
    To solve it, you do this..
    int useIt = value & 0xff;or never store it as a byte in the first place.
    This is what you have to do when reading bytes out of byte arrays...
    int useIt = byteArray[index] & 0xff;

  • BUG - Create Offline View, negative values are mangled

    Studio Edition Version 10.1.3.0.4.3673
    Platform: OS/X
    Create an offline view with SQL declaration
    SELECT
    (-1 * 5)
    FROM
    dual
    Test Syntax result is "No errors found in SQL"
    Click Next, and view has been rewritten as
    SELECT
    1 - * 5
    FROM
    dual
    This behaviour prevents import of any view which contains a negative value, ie
    SELECT
    decode( sign(4-5), -6, null, 1)
    FROM
    dual
    is converted to
    SELECT
    decode( sign(4-5), 6 -, null, 1)
    FROM
    dual

    Thanks for reporting this issue, I have filed bug 5064419 for this issue.
    Regards,
    Lisa
    JDev QA

  • Stock Posting List - Negative Value when Different Currency in PO

    Hi experts,
    We would like your help on the following scenario.
    A Purchase Goods Receipt PO and a Purchase Invoice are added in SAP 9.0, on the same date, in a different currency from the system's currency; system's is Euro and Purchase documents are added in JPY (Japanese xen), i.e. 300 JPY. When checking the "Stock Posting List" report for a number of goods that were purchased with the above documents, the report presents the line of the Goods Receipt PO with the value of 270 JPY, and the line of the Purchase Invoice with  a negative value, i.e.-15 Euro.
    Has anyone faced the same issue?
    Thank you in advance.
    Kind Regards,
    Vassilis Korolis

    Both queries have the default value of  "Only Posted Values for Navigation".
    As I was looking at this, I did realize the following though.
    Remember, I mentioned that my zcurrency_mand field has a Reference Characteristic of 0currency.
    Query 1:  The key figure that is being converted is tied to 0currency in the back end. (this is the query that works).
    Query 2:  The key figure that is being converted is tied to 0inv_curr in the back end.
    Both of the currency conversions are using zcurrency_mand.  Should query 2 be using a new variable similar to zcurrency_mand, but with a Reference Characteristic of 0inv_curr?
    If the answer is yes, I tried creating ZINV_CURR_MAND with Reference Characteristic of 0inv_curr, but am getting the following error when I try to save the changes to Query 2
    [E117(BRAIN)] Errors: Variable ZINV_CURR_MAND2 is not permitted for the target currency. 
    Thanks,
    Jennifer

  • How to enter negative value in a currency field

    Hi Experts,
    Please help me how to allow to enter negative value in a field on report selection.
    I created a currency field on a report selection using PARAMETERS.
    I can enter positive value in the field. But, I cannot enter negative value.
    SAP shows an error message 00 126 "Specify positive values only".
    I know I can place check ON at "with sign" option of the field in case I create the screen by myself.
    However, I cannot do it on screen 1000 created by report program.
    Thanks,
    George

    Hi ,
    I know I can place check ON at "with sign" option of the field in case I create the screen by myself.
        Prabhu--> Just Create a new Domain( select "WITH SIGN") and date elemet,And Use Data Element in your report.
    regards
    Prabhu

  • Conditions type of category "Delivery Costs"(B) donu00B4t allow negative values

    Hello,
    I would like to know if it is possible to munipulate a condition type with category "B" Delivery costs in such a way that it allows a negative entry in the Purchase Order.
    Estandard SAP does not allow it. Message: 06259 "Negative Delivery costs are not allowed".
    If the above is not possible, can anyone tell me how a can manipulate a Discount (fixed amount) in such a way that it not only points at a particlar account (accruels indicator does this job) upon MIGO, but also apears as a line-item upon receiving the invoice (MIRO). As far as I know, only Planned delivery costs can do this job. But they do not allow negative values!
    If anyone has encountered a similar task, please tell me how they solved it.
    Thanks,
    Aart

    Hello Guys,
    The scenario isas follows.
    When one buys fuel, in Chile  one has to pay fuel especific Taxes.
    Version especific config does not resolve this because we need the tax in amount (value) not in percentage.
    In our system we resolved this by creating a material "Fuel especific Taxes" which points at a tax-account  with a special tax-indicator.
    So far so good.
    Now the government implemented a second fuel tax - "Fuel tax variable" which we might resolve in the same way, but the problem is this tax might be negative(!).
    We cannot create a material with a "negative value" in our Purchase Order and discount conditions have inmediate efect on the material costs in the PO.
    The ideal would be incorporate a condition type in the PO which upon invoicing (MIRO) shows up with the tax account (and a possible negative value!
    The model we have developed upto now is using the tabpage "GeneralAccount" in the MIRO but in this model we have to indicate the account ourselves. The system does not propose it.
    Thats why I thought of the "Planned Delivery costs" option.
    Hope this clarifies a bit more the case we have.
    Thanks for any feedback
    Aart

  • Service PO Creation With Negative value

    Hi all,
    I am trying to create a Services PO using the BAPI 'BAPI_PO_CREATE1'
    In my scenario, First time PO will create with negative value.
    Then I will remove some conditions in Services line.
    Then PO value will becomes positive.
    When i create the bapi in ME21N, its working fine. Net values of PO become negative.
    But When I try the same using the BAPI, net price of the PO stored as 0(ZERO).
    If I create a PO with positive value using the same BAPI, everything is fine.
    If I change the PO after creation(removing the service line to make bapi value as positive), Net values are doubled since value stored as zero instead of negative value.
    Kindly help me to get out of this issue.
    Note: I need to create a Services PO with negative value using the BAPI
    Thanks in advance.

    Hi,
    No need to create service PO with negative quantity!
    If payment not done for your servicePO, you can cancel invoice document and then revoke SES.
    If any other process involved you can do subsequent debit or subsequent credit  for your service PO in t.code:MIRO.
    Regards,
    Biju K

  • Select returns negative values for unsigned datatypes in MySQL DB

    Hi, I have a table in a MySQL database where some fields are declared as "unsigned".
    Example:
    CREATE TABLE countries (
    Country_id SMALLINT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
    Number SMALLINT UNSIGNED NOT NULL
    My problem is when inside a .xsql file, I try to do a select:
    <xsql:query>
    select Number from countries where Country_id="15"
    </xsql:query>
    If inside the Database, Number always goes from 0 to 65535 (UNSIGNED SMALLINT),
    the resulting XML of that query will always show negative values if Number is
    bigger than 32767 (so it ignores the "UNSIGNED").
    Have you seen something like this before? Do you kwno what I'm doing wrong or what
    can I do to retrieve the values unsigned?
    Thanks a lot!
    David

    hi muneer
    >
    We are facing a strange issue in our R12.1.3 Ebiz instance (DB 11.2.0.1) - Solaris Sparc 64 bit - 2 node (1 node Apps, 1 node DB).
    Some of the purchase orders are having a negative purchase order number.
    SQL> select segment1 from PO_HEADERS_ALL where segment1 < '0';
    SEGMENT1
    -7951814
    -8960847please see
    Error: Purchase Order Creation Could Not Be Initiated, But PO Was Created With Negative PO Number And No Distributions [ID 789464.1]     To Bottom     
    PO Creation Process Failed In Sourcing And Creates Document With Negative Numbers [ID 1479616.1]
    Purchase Order Receipt FAQ (P4312) [ID 1306869.1]
    How it could happen. Any suggestions please !looks like a bug
    Can a Purchase Order (PO) Be Created With Negative Quantity or Price? [ID 241389.1]
    AppsMasti
    Sharing is caring

  • Using decode function without negative values

    Hi friends
    I am using oracle 11g
    I have at doubt regarding the following.
    create table Device(Did char(20),Dname char(20),Datetime char(40),Val char(20));
    insert into Device values('1','ABC','06/13/2012 18:00','400');
    insert into Device values('1','abc','06/13/2012 18:05','600');
    insert into Device values('1','abc','06/13/2012 18:55','600');
    insert into Device values('1','abc','06/13/2012 19:00','-32768');
    insert into Device values('1','abc','06/13/2012 19:05','800');
    insert into Device values('1','abc','06/13/2012 19:10','600');
    insert into Device values('1','abc','06/13/2012 19:15','900');
    insert into Device values('1','abc','06/13/2012 19:55','1100');
    insert into Device values('1','abc','06/13/2012 20:00','-32768');
    insert into Device values('1','abc','06/13/2012 20:05','-32768');
    Like this I am inserting data into table for every 5 minutes Here i need the result like
    output:
    Dname 18:00 19:00 20:00
    abc 400 -32768 -32768
    to retrieve this result i am using decode function
    SELECT Dname,
    MAX(DECODE ( rn , 1,val )) h1,
    MAX(DECODE ( rn , 2, val )) h2,
    FROM
    (SELECT Dname,Datetime,row_number() OVER
    (partition by Dname order by datetime asc) rn FROM Device
    where substr(datetime,15,2)='00' group by Dname.
    According to above data expected result is
    Dname 18:00 19:00 20:00
    abc 400 600(or)800 1100
    This means I dont want to display negative values instead of that values i want to show previous or next value.
    Edited by: 913672 on Jul 2, 2012 3:44 AM

    Are you looking for something like this?
    select * from
    select dname,
           datetime,
           val,
           lag(val) over (partition by upper(dname) order by datetime) prev_val,
           lead(val) over (partition by upper(dname) order by datetime) next_val,
           case when nvl(val,0)<0  and lag(val) over (partition by upper(dname) order by datetime) >0 then
             lag(val) over (partition by upper(dname) order by datetime)
           else 
             lead(val) over (partition by upper(dname) order by datetime)
           end gt0_val
    from device
    order by datetime
    where substr(datetime,15,2)='00';Please take a look at the result_column gt0_val.
    Edited by: hm on 02.07.2012 04:06

  • Acquisition of an Asset with Negative value

    Hi Gurus,
    How to do acquisition of an asset with negative value?
    Please tell me the Tcode for doing this transaction.
    Please revert asap.
    Thank You

    Hi,
    The business scenario is.............
    We have to charge some interest on asset last year but we have not charged it.
    Now asset value is zero and if we charge interest on it, it will go to negative.
    That's we are thinking to create new asset with negative value.
    Hope this will help you understand.
    Please revert asap.
    Thank You

  • Service Purchase Order with Negative Value

    Hi Experts,
    is there a method of creating a purchase order of services that can have negative value on it?
    the requirement is that the PO, SES and Invoice of the previously issued PO needs to be adjusted by creating a new Purchase order.
    Please advise.
    Thank you,
    Barakzai.

    Hi,
    No need to create service PO with negative quantity!
    If payment not done for your servicePO, you can cancel invoice document and then revoke SES.
    If any other process involved you can do subsequent debit or subsequent credit  for your service PO in t.code:MIRO.
    Regards,
    Biju K

  • Credit note for invoice with item with negative value

    Hi,
    is it possible to create credit note for invoice, where in one line is negative value (its non stock item).
    There exists 2 possibilities:
    negative qty and positive price (its possible create only through SDK, not SBO)
    positive price and negative qty
    for example
    itemcode 123
    qty -1
    price 1000
    How to create credit note from this invoice?
    Thanks a lot for hints.
    Petr

    Hello Petr Verner,
    It's a standard functionality of Business one, that it is impossible to enter a negative amount in an independant credit note or in a credit note based on a invoice with negative amount.
    To solve this issue:
    1.  For the rows with the positive Row Total, create an "independent" Credit Memo (not based on an Invoice).
    2.  For the rows with the negative Row Total, create another Invoice with a positive Row Total opposite to the original negative Row, and reconcile between the two rows manually via Banking => Bank Statements and Reconciliations => Reconciliation.
    Hope the above helps.
    Wilma Wang
    SAP Business One Forums Team

  • Stacked bar chart with negative values

    Hi,
    trying to create a stacked bar chart I only get a grey picture. Reason: my data series provides positive and negative values.
    Can anyone tell me a trick how to fix this problem?

    User614143,
    try to add the minumm negative value (but positive) to the parameter for the axis.
    e.g. show value+3000 (assuming -3000 is the minimum value)
    If you don't have a limitation for the negative values, it doesn't work. (or try to calculate first the most negative value in a before header process)
    hope this helps.
    Leo

  • Print out of Report Region dropping negative values

    I am very new to APEX (< 2 months) and don't have much of a programming background. I have created a report layout using BI publisher and made it available as a shared component in my APEX applicaiton. When I print the the report region, most of the data displays fine on the print out, but any amounts with negative values are suppressed. I can view the negative amounts just fine when they are displayed on the report region itself.
    It took me quite a while to get the style sheets from BI Publisher to work with APEX. I thought the two were supposed to be compatible. Does anyone know how to resolve the issue above or if their are any known compatability issues between BI Publisher and APEX? We are on APEX version 4.2.1.00.08 and BI Publisher version 11.1.1.

    This was indeed a bug. Response from Oracle:
    This issue has been noted by development as a bug and I have file bug 16224878 regarding your issue. The issue explained by development pertains numeric format string which wraps the negative value in angle brackets: < val > , and the report is treating this as a HTML tag and filters it out. It looks like this is happening only for classic report regions, i.e. report queries seems to support this type of numeric format mask.
    A work around would be to turn off printing for the classic report region and to provide a button to a report query for printing, using the same SQL for the report query as is used for the report region. Alternatively you could also use a different format mask.

  • Issue with Negative Value for Total valuated stock 0VALSTCKQTY.

    Hi Experts,
    we loaded the Cube with datasources 2LIS_03_BX, 2LIS_03_BF and 2LIS_03_UM.
    We mapped the quanity field from 2LIS_03_BF in transformation either into Key figures "Quantity issued from valuated stock" (0ISSVALSTCK) or "Quantity received into valuated stock" (0RECVALSTCK ) of the cube.
    For obtaining the Total Valuated stock, we used the Key figure 0VALSTCKQTY. This key figure is having the Inflow and Out flow values as 0RECVALSTCK and 0ISSVALSTCK. When i tried to check the content of 0VALSTCKQTY, the key figure  0VALSTCKQTY is not present in the infoCube content. I understood that the value for this key figure would be calculated at the time of query execution with the formula
    { Last obtained Valuated stock + (Received Valuated Stock u2013 Issued Valuated Stock ) }.
    The issue is the first records in the query is obtained with negative value for the total valuated stock 0VALSTCKQTY even though the values of Received Valuated Stock  and  Issued Valuated Stock are with Zero.  Could any one please help me on how the first record in the query is with a negative value eventhough the inflow and out flow fields of it are with Zero.
    Many Thanks in advance.
    Jeswanth

    Hi Srini,
    I observed an interresting reason for the stock being with negative in the first record.
    Issue : While executing the BEx report, we have the first record with a negative value.
    Let me explain with an example
    Material  : XYZ
    Plant      : A
    Date of Stock Initialization for data source 2LIS_03_BX -
    >  12th April 2009.
    So on 12 Th April 2009 consider that we have a stock in store with a value of 2640.
    Then we have loaded wih Data source 2LIS_03_BF for all Historic Movement types.
    At the time of query execution we will have the first record with a negative of available stock present on the day of initialization .
    So, as we have initilized the data source 2LIS_03_BX on 12 th April 2009, we have at that time a stock of 2640 in availability.
    Exactly with the same value of 2640, we are having a negative value i.e. -2640.
    and also one more point to be noted is ...as we have initialized the data source 2LIS_03_BX on 12 th APril 2009...it has created a
    opening balance of 2640 on the day of initiailization i.e on 12 th April 2009 in infocube....(which is an extra record...)...so if the previous record of 12,04,2009 is having some value in it..then it will get added to 2640 EA..which will give incorrect stock
    So in the query the records will appear in the below following manner
    Calendar Day     Total stock                                                                Received stock                                          Issued Stock         
    28.12.2005 --->  - 2640 EA
    29.12.2005 --->    2000 EA                                                                       640 EA                                                        0
    10.04.2009 --->      0                                                                                0                                                               2000 EA      
    11.04.2009 -
    >    0                                                                                0                                                                0          
                                 (For making
                                  the earlier record of  initilization to 0  a negative value -2640 EA is created in the first record )
    12.04.2009 (Initializtion day) --->  2640 EA                                                 0                                                                0
    13.04.2009 
    the day before initialization the total stock will be 0 due to the negative effect introduced by the first record and from the day of initialization the records will be the accurate values...  On 12 th april 2009 we can see that a stock of 2640 is brought into the total stock. In fact if there is no negative value i.e. -2640 in the first record then ...the value on 11.04.2009 will be 2640 Ea and this will get summed up with the Opening balance of 2640 EA created by 2LIS_03_BX on the day of intitialization. So on 12 .04. 2009 the total stock will be shown as 5280 EA...so in order to prevent the double value only we observed that the first record is created with the negative of available stock present on the initialization ...to make the record before the day of initialization i.e. 11.04.2009...to be 0...so that from 12 th April 2009 ..will start to see the actual total stock in the query result...
    This is happening only if we use  both the data sources 2LIS_03_BX and 2LIS_03_BF  for loading into BW.....
    If we load alone by 2LIS_03_BF ...then as 2LIS_03_BX is ruled out in the loading...then no negative of available stock will be created ...because there will be bno opening balance created on the day of initialization.....and the opeing balance available will be flowing into consecutive records due to the movement types and 12 th April 2009 will be shown with avaialable total stock of 2640 EA.
    Kindly let us know your opinions on this...
    Thanks.
    regards,
    Jeswanth

Maybe you are looking for

  • Condition Type in VA01

    Hello experts, There is a column by the name "Condition Type" in the Sales Order creation (VA01) transaction. Could you please let me know the table in which I can find which sales order is containing which all condition types? I am totally a technic

  • Retrieving lots of rows through XSQL servlet

    Hi Steve! I am currently trying to break XSQL-servlet in order to have some proof of usability for our customers. During one of these 'sessions' I discovered that the XSQL servlet throws me out with an exception error (out of memory) when I try to re

  • Over and Under Delivery Tolerance Defaults

    Hi ! Is there a way to provide a default Over and Under Delivery Tolerance % at Company Code or Purchising Org level? If yes, please let me know what the menu path is to make that setting. Our tolerance for Over delivery is 10% standard across the bo

  • Problem in table maintenance

    Hi Gurus. I created one ztable and also table mainenance . but in sm30 the table is not showed blank screen is showing. here I am not able to create entries. please give me the reply. Regards, Shashikumar.G

  • Help please - occasional shut-down after sleep & kernel panic

    Hi all. I have an intermittent problem here with an iMac 24in 2.66Ghz Intel Core 2 Duo model. This iMac was bought refurbished from the Apple store about 6 weeks ago. About once a week, after putting the iMac to sleep, I come back to it later to find