Which the cost of using a constructor in big model class ?

Hello for all
I am having to do a find and I have an entity(model) with 20 parameters.
The question is:
It is better to ask (by if's) if the parameters are null, if they go I pass null for the object, or to carry that object with the parameters, to use empty strings when it has not data for example, and to send it like this.
Which the cost of the operations in terms of expenses with processor in the first option and memory on secondy? Which the most advantageous?
I thank the collaboration
Thanks

I think the best way to use null. So we can first check whether it is null or not. If it is not null we can proceed further.
Looking performance i think this is better option.

Similar Messages

  • HT204023 What are the costs to use a personal hotspot

    Does anyone know the cost to use a personal hot spot.

    Personal Hotspots are control by your carrier. My carrier is Verizon and with my plan there is no additional cost for a hotspot.

  • What's the advantage of using JSF than other MVC model

    What's the advantage of using JSF than other MVC model ?
    eg, Any advantage of using JSF than struts? What's their main difference?

    There is a good picture that shows that JSF brings new. You can find this picture on the page #9 of the "All about JavaServer Faces" by Kito Mann.
    URL:  http://www.cppsig.org/nycjava/All%20about%20Faces%20-%20NYPCUG%20-%2004-2004.pdfActually, you can search for "jsf vs struts" on this forum and find a lot of interesting material regarding to this topic.

  • How to update the COST column using another table's column

    Dear All,
    I have table:
    table parts: pno, pname, qoh, price, olevel
    table orders: ono, cno, eno, received, shipped
    table odetails: ono, pno, qty
    view:orders_view: ono, cno, eno, received, shipped,sum(qty*price)order_costview:odetails_view: ono, pno, qty, (qty*price)cost
    after I update the price in parts, I need to update COST and ORDER_COST too. The orders_view does not have pno, qty, and price, the odetails_view does not have price, how can I update the COST and ORDER_COST. Please help and Thanks in advance!!!
    I wrote the update the price in parts:
    create or replace procedure change_price(ppno in parts.pno%type, pprice in parts.price%type) as
    begin
        update parts
        set price = pprice
        where pno = ppno;
    end;
    show errorsthis procedure works fine.
    I wrote the trigger:
    create or replace trigger update_orders_v
    after update of price on parts
    for each row
    begin
        update orders_view
        set order_cost = sum(parts.(:new.price)*parts.qty)
        where parts.pno = :new.pno;
    end;
    show errorsIt gives me:Errors for TRIGGER UPDATE_ORDERS_V:
    LINE/COL ERROR
    3/5 PL/SQL SQL Statement ignored
    4/22 PL/SQL ORA-00934: group function is not allowed hereplease help!

    You could add the columns to the tables and then you would need a trigger to update those columns. However, you could just as easily select the price * qty to get the cost, without creating an additional column or trigger. I have no idea what you might want to do with a global temporary table. I think you need to explain what your purpose is, before any of us can suggest the best method. Since I have already demonstrated an update with a view, I will demonstrate an update with the cost column added to the odetails table and a trigger as you asked about. Notice that you will need triggers on both tables, the one that has qty and the one that has price.
    scott@ORA92> create table parts
      2    (pno    number(5) not null primary key,
      3       pname  varchar2(30),
      4       qoh    integer check(qoh >= 0),
      5       price  number(6,2) check(price >= 0.0),
      6       olevel integer)
      7  /
    Table created.
    scott@ORA92> create table odetails
      2    (ono    number(5),
      3       pno    number(5) references parts,
      4       qty    integer check(qty > 0),
      5       cost   number,
      6       primary key (ono,pno))
      7  /
    Table created.
    scott@ORA92> create or replace procedure change_price
      2    (ppno   in parts.pno%type,
      3       pprice in parts.price%type)
      4  as
      5  begin
      6    update parts
      7    set    price = pprice
      8    where  pno = ppno;
      9  end;
    10  /
    Procedure created.
    scott@ORA92> create or replace trigger update_cost1
      2    after insert or update of price on parts
      3    for each row
      4  begin
      5    update odetails
      6    set    cost = qty * :new.price
      7    where  pno = :new.pno;
      8  end update_cost1;
      9  /
    Trigger created.
    scott@ORA92> show errors
    No errors.
    scott@ORA92> create or replace trigger update_cost2
      2    before insert or update of qty on odetails
      3    for each row
      4  declare
      5    v_price parts.price%type;
      6  begin
      7    select price
      8    into   v_price
      9    from   parts
    10    where  pno = :new.pno;
    11    --
    12    :new.cost := :new.qty * v_price;
    13  end update_cost2;
    14  /
    Trigger created.
    scott@ORA92> show errors
    No errors.
    scott@ORA92> insert into parts values (1, 'name1', 1, 10, 1)
      2  /
    1 row created.
    scott@ORA92> insert into odetails values (1, 1, 22, null)
      2  /
    1 row created.
    scott@ORA92> -- starting data:
    scott@ORA92> select * from parts
      2  /
           PNO PNAME                                 QOH      PRICE     OLEVEL
             1 name1                                   1         10          1
    scott@ORA92> select * from odetails
      2  /
           ONO        PNO        QTY       COST
             1          1         22        220
    scott@ORA92> -- update:
    scott@ORA92> execute change_price (1, 11)
    PL/SQL procedure successfully completed.
    scott@ORA92> -- results:
    scott@ORA92> select * from parts
      2  /
           PNO PNAME                                 QOH      PRICE     OLEVEL
             1 name1                                   1         11          1
    scott@ORA92> select * from odetails
      2  /
           ONO        PNO        QTY       COST
             1          1         22        242
    scott@ORA92> -- select works without extra cost column or trigger:
    scott@ORA92> select o.ono, o.pno, o.qty, (o.qty * p.price) as cost
      2  from   odetails o, parts p
      3  where  o.pno = p.pno
      4  /
           ONO        PNO        QTY       COST
             1          1         22        242
    scott@ORA92>

  • Need to know the program names to which the table is used

    Hi,
    I am using a table <table1>.
    For Example : MARA table. I need to know in what are all the program's the MARA table is used .
    Please let me know in which tcode can I know the details.
    Thanks,
    Karthik

    hi ,
    use program 
    RS_ABAP_SOURCE_SCAN
    passs 'MARA' IN search field 
    and  program name field  '*'
    will give all  program .
    regards
    Deepak.

  • What is the cost to use my phone in Malawi?What temporary add-ons are available?

    I am travelling to Malawi this month for 1 month. I will need some form of communication out there. I expect I will probably buy a phone and international SIM whilst I'm there, but before I do so I wanted to explore what I can do with my current plan. I am on an EE Regular 2gb plan. Unlimited minutes and texts within the UK and 2gb data. I have no roaming minutes/texts as part of my plan. So my questions are: What add-ons are available so that I can use my phone in Malawi (Africa)? - I have had a brief look on the website, but these seem to only go up to 120 minutes, which is not a great deal and I would need more. Also I don't currently have my phone insured. If I was to get it insured through EE would it cover me against theft - whilst in Africa or anywhere else for that matter? I could buy an international SIM now, but assume my iPhone is locked to EE? Thanks for any help!

    Text RO MALAWI to 150 to see the rates & add-ons.
    Your phone will be locked to EE.

  • What is the cost of using ThreadMXBean.findMonitorDeadlockedThreads() ?

    HI, we are planning to setup some alerting to check if any thread in monitor status for too long, say 15mins
    So just wonder, if the API call
    http://download.oracle.com/javase/6/docs/api/java/lang/management/ThreadMXBean.html#findMonitorDeadlockedThreads()
    Is very expensive or not? Will it cause preformance problem of checking it for every minutes?

    An iPod touch costs roughly 16000 for the 8GB model and 21000 for the 16GB model in India.
    (27797)

  • How to get the cost center and division for a given FI vendor document...

    Hello Experts,
    I am currently developing a report wherein I have to show the cost center and division used in the given FI document.
    These documents are vendor related transactions.
    In the file that was given to me by the user, she indicated the cost centers used by the FI documents
    but when I view it via VA03 I cannot theere are no cost centers used in all the line items.So are there
    any FM, BAPIs and/or tables that I can use for my requirement?
    Hope you can help me guys. Thank you and take care!

    Hi
    I am not sure on the requirement. You are developing a FI report and accessing VA03 which is sales transaction. Anyway for getting cost center you can go to table VBAK,VBAP for line items.
    Hope solves ur problem
    Thiru

  • How to rerun the costing in the Billing document.

    Hi,
    I am working for an client who belongs to Cable Industry, we are capturing the costing in the sales order and pricing is based on the costing.
    We are capturing the pricing in Ek02, on this we are adding the profit margin.
    As Copper price is always changes in some cases client want to charge more or less the difference amount at the time of creating the invoice. The sales order may partially delivered and billed. In this case also client want to change the price.
    How can we incorporate the change of copper price in the billing document as i cannot run the costing once again in the sales order for the balanced quantity, and client want this calculation to be done by system itself during billing.And SAP has not given any provision to run the costing during billing document.
    Kinldy suggest how to proceed further.
    Thanks & Regards,
    Kumar.

    Hi,
    My client belong to cable industry, so copper becomes the major rawmaterial which changes daily.
    So, sometimes based on the customer request if the invoicing is done after 3 months from the date of sales order
    then we  need to update the price at the time of invoicing.
    In sales order we are running the costing and using the variant configuration Module in th project.
    And after production at the time of invoicing client is asking to put the changed prices (Ex. Copper, GI Wire and PVC component) for which prices will be announced by the LME.
    So, kindly suggest me how to re run the costing in the billing or is there any alternative to define separate condition types for Copper, GI Wire etc.
    Awaiting for your reply,
    Thanks & Regards,
    Tilak.

  • Tablesstoring the cost planning quantities distributed over periods in CJ40

    Hello experts,
                        Can u tell me the tables in which the cost planning quatities distributed over periods in CJ40 transaction are stored

    Hi
    RPSCO is table where you can see the cost& revenue.
    Use PROJ get object no. and then enter this object no. in rpsco.
    hope this is useful.
    Regards,
    KP.

  • SQL Cost of using DECODE built-in

    I'm trying to tune some SQL and wondering about the cost of using DECODE. I believe that by using this function, it prevents any index on the related column from being used.
    Do any "Tuning Gurus" have opinions on the use of DECODE?
    TIA,

    As a general rule, the Oracle built-in functions are pretty fast to execute. You will not really see any difference in performance between a sql statement using a built-in function in the SELECT clause, and one not using one.
    However, a lot depends on where and how you use the DECODE.
    SELECT col1,DECODE(col2,1,'YES',2,'NO',3,'MAYBE')
    FROM table
    will be no slower than
    SELECT col1,col2
    FROM table
    If there is an index on col2, then
    SELECT col1,DECODE(col2,1,'YES',2,'NO',3,'MAYBE')
    FROM table
    WHERE col2 BETWEEN 1 AND 3
    will use it.  However
    SELECT col1,col2
    FROM table
    WHERE DECODE(col2,1,'YES',2,'NO',3,'MAYBE') IN ('YES','NO','MAYBE')
    will not (unless you have a function based index).  But,
    SELECT col1,col3
    FROM table
    WHERE col2 BETWEEN 1 and 3 and
          col3 = DECODE(col2,1,'YES',2,'NO',3,'MAYBE') IN ('YES','NO','MAYBE')
    will.Note that "will" in the above really means can. it is up to the optimizer whether it actually is used or not.
    HTH
    John

  • Cost assignement using infotype 2003

    Hello,
    How can I change cost assignement using Infotype 2003.
    I have created the infotype 2003 with the ney cost center, and table  C1 is generated in the time evaluation, but in payroll the cost center is still the master cost center of IT0001.
    How can I change the cost center using infotype 2003 and transfered to the payroll?
    thx.
    Enrique

    Thanks Santhosh for the answer.
    So I can understand that the cost center will not be changed from IT2003 for the payroll, it only be changed if change in IT0001 or IT0027. true?
    Why IT2003 have the option to change cost assignment?
    I was doing some tests and could see that if a time wage type (for example an attendance) is generated in the same period of the IT2003 these wage type is transfered to the payroll with the new cost assignment . Is it the standard behavoir of the IT2003?
    The only way to change the cost assignment for all the payroll (instead of IT0001) for a period is using IT0001 or IT0027?
    thanks,
    Enrique

  • Cost receivers use  in PM

    Hi Experts ,
    which is cost receivers use  in PM
    With best regards,
    AVI DDS.

    Hi,
    In PM cost receiver is linked to settlement of work order.Wherein during settlement cost is moved from work order to settlement receiver which is cost receiver.This receiver is part of controlling and can be either single or multiple cost centres,WBS,internal order etc.
    Cost receiver during settlement receives costs from work order which are comined or cumulative cost of internal labour cost + material cost+service cost etc.
    regds,
    atul

  • Precaution for releasing the cost estimate

    Hello friends,
    What are the precautions to  be taken for releasing the cost estimates.
    Like any delivery are done and invoices to to made in Sales.
    What are the other precautions. Please let me know, as we have to release the cost estimate in production.
    Regards,
    SK

    Hi,
    do you mean released to standard price?
    1: cost estimate needs status "costed without error".
    2: marking allowance in CK24 must be set for company code/period for the costing variant used.
    3: Costing variant is assigned to a costing type that allows price update to standardprice.
    4: Cost estimate is marked (without errors).
    Aftre that its possible to release the cost estimate to S-price.
    best regards, Christian

  • Which functional modules we can use to update the costs in WBS?

    Hello friends,
         I need to update the costs assigned to WBS elements at cost element level using TCode CJR2. Which function modules are available to do this?
    Can you show me sample implementation for the same?
    Thanks in advance,
    Amol C.

    You can't.
    A UIImage object is a high-level way to display image data. You can create images from files, from Quartz image objects, or from raw image data you receive. The UIImage class also offers several options for drawing images to the current graphics context using different blend modes and opacity values.
    Image objects are immutable, so you cannot change their properties after creation.

Maybe you are looking for

  • Jabber voicemail address cert warning

    Hello. I hope someone can help me with this. I have tried to change all setting to use FQDN and also adde certificates issued by our internal PKI. it works for CUCM and IM&P connections, but jabber still complains that on the certificate for VM. What

  • Need Time Capsule to join new existing network after Uverse box swap SSID

    When I first bought my Time Capsule it was creating my wireless network. Then last year we moved to a new house, and got Uverse service. I successfully changed Time Capsule's config to join the existing Uverse network, so the TC does backup and nothi

  • How do I publish a website in two languages?

    Hi! I'm pretty new to IWeb, I'm trying to publish my website in Spanish, and also in English. How do I do this without duplicating the buttons in the navigation bar? Say I want a flag to be the switch button, and then when I go to the Welcome page in

  • Return key breaks dialog boxes

    I have illustrator cs5 on snow leopard. When I open up a dialog box I often try to push enter when I'm done typing stuff to close it.  The OK button is highlighted so you'd think this would work. But no, instead it just completely breaks the dialog. 

  • I am having problems downloading updates to my apps.

    Some apps are updating without any problems but apps like fifa12 have refused to update for as long as I can remember. I have repeatedly tried to update the apps but I get a waiting status on the app, is there something I am doing wrong help somebody