Sorting in the procedure

will it possible to do sorting in the procedure. I have tried to do it like below and sorting does not seem to work.
CREATE OR REPLACE PROCEDURE VENDORSEARCH
( P_VENDORNAME IN VARCHAR2,
  P_VENDSEARCHSELECTION IN NUMBER,
  P_SORTEXP IN VARCHAR2,
  P_RESULT OUT SYS_REFCURSOR
IS
-- VENDORSEARCHNAME  VARCHAR2 (20) := '%'||UPPER(P_VENDORNAME);
BEGIN
         OPEN  P_RESULT FOR
SELECT   v.vendor "Vendor Id", r.addrnum, INITCAP (v.vnamel) "Vendor Name",
         r.aaddr1, INITCAP (r.acity) city, r.vasst1, r.astate state, r.azipcode,
         TO_CHAR (MAX (p.datepur), 'MM/DD/YYYY') "Last Plan Purchased Date",     
         INITCAP (TRIM (r.aaddr1 || DECODE (TRIM (r.aaddr2), NULL, '', ' - ') || r.aaddr2 )  ) address,
         SUBSTR (DECODE (TRIM (r.vasst1), NULL, 'N/A','000/000-0000?', 'N/A','000/000-0000', 'N/A', r.vasst1 ), 1,  12  ) fax,
         SUBSTR (DECODE (TRIM (r.aphone), NULL, 'N/A','000/000-0000?', 'N/A', r.aphone ),  1, 12 ) phone
    FROM vendor v, vendaddr r, planhold p
   WHERE v.vendor = r.vendor
     AND p.vendor = r.vendor
     AND (p.datepur >= TO_DATE ('01-01-2000', 'MM-DD-YYYY'))
     AND p.datepur IN (SELECT MAX (p.datepur)
                         FROM planhold p
                        WHERE p.vendor = r.vendor)
     AND v.vobsolet = 'N'
     AND (UPPER (v.vnamel) NOT LIKE '%DISTRICT ENGINEER%'
          AND UPPER (v.vnamel) NOT LIKE '%RESIDENT ENGINEER%')
       --   AND UPPER (v.vnamel) NOT LIKE '%CITY ENGINEER%')
     AND UPPER (v.vnamel) LIKE
    CASE
     WHEN P_VENDSEARCHSELECTION = 1 THEN   UPPER(P_VENDORNAME) ||'%'
     WHEN P_VENDSEARCHSELECTION = 2 THEN   '%'||UPPER(P_VENDORNAME)
     ELSE '%'||UPPER(P_VENDORNAME)||'%'
    END
GROUP BY v.vendor, r.addrnum, v.vnamel, r.aaddr1, r.aaddr2, r.acity,r.astate, r.azipcode, r.aphone, r.vasst1, p.datepur
ORDER BY P_SORTEXP ;
END;
I get the same result in both ascending and descending order. thanks for the help.
Vendor Id      AD Vendor Name                                                  AADDR1                                   CITY                   
L0031          01 Luxury Landscaping & Lawn Care Llc                           260 COUNTY HWY 11                        Audubon                
L520           01 Lucas Co                                                     29191 VERDIN ST NW                       Isanti                 
L550           01 Lunda Construction Co                                        620 GEBHARDT RD                          Black River Falls      
L550           02 Lunda Construction Co                                        15601 CLAYTON AVE S                      Rosemount              
L571           01 Lundin Const Of Cromwell                                     1439 HEATHER LANE                        Cromwell               
SQL> EXEC VENDORSEARCH('LU,1,'V.VNAMEL ASC', ;RC);
ERROR:
ORA-01756: quoted string not properly terminated
SQL> EXEC VENDORSEARCH('LU',1,'V.VNAMEL desc, :RC);
PL/SQL procedure successfully completed.
SQL> PRINT;
Vendor Id      AD Vendor Name                                                  AADDR1                                   CITY                   
L0031          01 Luxury Landscaping & Lawn Care Llc                           260 COUNTY HWY 11                        Audubon                
L520           01 Lucas Co                                                     29191 VERDIN ST NW                       Isanti                 
L550           01 Lunda Construction Co                                        620 GEBHARDT RD                          Black River Falls      
L550           02 Lunda Construction Co                                        15601 CLAYTON AVE S                      Rosemount              
L571           01 Lundin Const Of Cromwell                                     1439 HEATHER LANE                        Cromwell               
[pre]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

Thank you for your help. Actuall I did it this way.
CREATE OR REPLACE PROCEDURE WebTrnsportVendorsearch (
   p_vendorname            IN       VARCHAR2,
   p_vendsearchselection   IN       NUMBER,
   p_sortexp               IN       VARCHAR2,
   p_result                OUT      sys_refcursor
IS
BEGIN
   OPEN p_result FOR 
   'SELECT   v.vendor vendorId , r.addrnum, INITCAP (v.vnamel) vendorName ,
         r.aaddr1, INITCAP (r.acity) city, r.vasst1, r.astate state, r.azipcode,
         INITCAP (TRIM (r.aaddr1 || DECODE (TRIM (r.aaddr2), NULL, '''', '' -  '') || r.aaddr2 )  ) address,
         SUBSTR (DECODE (TRIM (r.vasst1), NULL,''N/A'',''000/000-0000?'', ''N/A'',''000/000-0000'', ''N/A'', r.vasst1 ), 1,  12  ) fax,
         SUBSTR (DECODE (TRIM (r.aphone), NULL, ''N/A'',''000/000-0000?'', ''N/A'', r.aphone ),  1, 12 ) phone,
         TO_CHAR (MAX (p.datepur), ''MM/DD/YYYY'') LastPlanPurchasedDate,        
         TRUNC(MAX(p.datepur)) PlanPurchasedDate
    FROM vendor v, vendaddr r, planhold p
   WHERE v.vendor = r.vendor
     AND p.vendor = r.vendor
     AND (p.datepur >= TO_DATE (''01-01-2000'', ''MM-DD-YYYY''))
     AND p.datepur IN (SELECT MAX (p.datepur)
                         FROM planhold p
                        WHERE p.vendor = r.vendor)
     AND v.vobsolet = ''N''
     AND (UPPER (v.vnamel) NOT LIKE ''%DISTRICT ENGINEER%''
          AND UPPER (v.vnamel) NOT LIKE ''%RESIDENT ENGINEER%'')
       --   AND UPPER (v.vnamel) NOT LIKE ''%CITY ENGINEER%'')
     AND UPPER (v.vnamel) LIKE
    CASE
     WHEN :C1 = 1 THEN   UPPER(:B1) ||''%''
     WHEN :C2 = 2 THEN   ''%''||UPPER(:B2)
     ELSE ''%''||UPPER(:B3)||''%''
    END
GROUP BY v.vendor, r.addrnum, v.vnamel, r.aaddr1, r.aaddr2, r.acity,r.astate, r.azipcode, r.aphone, r.vasst1, p.datepur
ORDER BY ' || p_sortexp
   USING P_VENDSEARCHSELECTION,
         p_vendorname,
         P_VENDSEARCHSELECTION,
         p_vendorname,
         p_vendorname  ;
END;

Similar Messages

  • Sorting for the procedure is not working

    can you help why the sorting is not working here.I am running the below procedure to sort asc and desc and when I do sort in descending order by a different column it gives me a different rows sorted in desc order. what i
    want the proecdure to do it to sort the recordset in asc and desc order without changing the selected rows
    SQL>  exec trnsportitems.gettrnsportitems(1,10,'itemnumber desc', :n, :c);
    PL/SQL procedure successfully completed.
    SQL> print c;
    ITEMNUMBER              R IDESCR                                   IDESCRL                                                      IUNI IS I ITEM
    2011.601/00002          1 TUNNEL CONSTRUCTION LAYOUT STAKING       TUNNEL CONSTRUCTION LAYOUT STAKING                           LS   0
    2011.601/00003          2 CONSTRUCTION SURVEYING                   CONSTRUCTION SURVEYING                                       LS   05 N 2011601/00003
    2011.601/00010          3 VIBRATION MONITORING                     VIBRATION MONITORING                                         LS   05 N 2011601/00010
    2011.601/00020          4 REVISED BRIDGE PLANS                     REVISED BRIDGE PLANS                                         LS   05 N 2011601/00020
    2011.601/00040          5 DESIGN                                   DESIGN                                                       LS   05 N 2011601/00040
    2011.601/00050          6 DESIGN AND CONSTRUCT                     DESIGN AND CONSTRUCT                                         LS   05 N 2011601/00050
    2011.601/08010          7 SUPPLEMENTAL DESCRIPTION                 SUPPLEMENTAL DESCRIPTION                                     LS   05 N 2011601/08010
    2011.601/08011          8 SUPPLEMENTAL DESCRIPTION                 SUPPLEMENTAL DESCRIPTION                                     LS   05 N 2011601/08011
    2011.601/08012          9 SUPPLEMENTAL DESCRIPTION                 SUPPLEMENTAL DESCRIPTION                                     LS   05 N 2011601/08012
    2011.601/08013         10 SUPPLEMENTAL DESCRIPTION                 SUPPLEMENTAL DESCRIPTION                                     LS   05 N 2011601
    10 rows selected.
    SQL>
    SQL>  exec trnsportitems.gettrnsportitems(1,10,'idescr DESC', :n, :c);
    PL/SQL procedure successfully completed.
    SQL> print c;
    ITEMNUMBER              R IDESCR                                   IDESCRL                                                      IUNI IS I ITEM
    2563.613/00040          1 YELLOW TUBE DELINEATORS                  YELLOW TUBE DELINEATORS                                      UDAY 05 N 2563613/00040
    2563.602/00100          2 YELLOW TUBE DELINEATOR                   YELLOW TUBE DELINEATOR                                       EACH 05 N 2563602/00100
    2565.602/00940          3 YELLOW LED INDICATION                    YELLOW LED INDICATION                                        EACH 05 N 2565602/00940
    2502.602/00040          4 YARD DRAIN                               YARD DRAIN                                                   EACH 05 N 2502602/00040
    2411.601/00030          5 WYE STRUCTURE                            WYE STRUCTURE                                                LS   05 N 2411601/00030
    2557.603/00041          6 WOVEN WIRE FENCE                         WOVEN WIRE FENCE                                             L F  05 N 2557603/00041
    2557.603/00043          7 WOVEN WIRE                               WOVEN WIRE                                                   L F  05 N 2557603/00043
    2563.613/00615          8 WORK ZONE SPEED LIMIT SIGN               WORK ZONE SPEED LIMIT SIGN                                   UDAY 05 N 2563613/00
    2563.613/00610          9 WORK ZONE SPEED LIMIT                    WORK ZONE SPEED LIMIT                                        UDAY 05 N 2563613/00610
    2557.603/00035         10 WOODEN FENCE                             WOODEN FENCE                                                 L F  05 N 2557603/00035
    10 rows selected.

    Hi,
    user13258760 wrote:
    can you help why the sorting is not working here.I am running the below procedure to sort asc and desc and when I do sort in descending order by a different column it gives me a different rows sorted in desc order. what i
    want the proecdure to do it to sort the recordset in asc and desc order without changing the selected rowsAs it is written now, the argument insortexp has nothing to do with the order of the rows. It is used only in computing column r, and column r is used only in the WHERE clause.
    Are you really saying you don't want a WHERE clause at all in the main query: that you always want the cursor to contain all rows from itemlist that meet the 3 hard-coded conditions:
    ...                     WHERE item  '2999509/00001'     -- Did you mean != here?
                              AND iobselet = 'N'
                              AND ispecyr = '05'?
    If so, change the main query WHERE clause:
    WHERE r BETWEEN instartrowindex AND inendrowindexinto an ORDER BY clause:
    ORDER BY  rBy the way, you might want to make insortexp case-insensitive.
    In your example, you're calling the procedure with all small letters in insortexp:
    user13258760 wrote:
    SQL> exec trnsportitems.gettrnsportitems(1,10,'itemnumber desc', :n, :c);but the output is coming in ASC ending order:
    ...                           ORDER BY
                                     DECODE (insortexp, 'itemnumber ASC', item) ASC,
                                     DECODE (insortexp, 'itemnumber DESC', item) DESC,     -- capital 'DESC' won't match small 'desc'
                                     DECODE (insortexp, 'idescr ASC', idescr) ASC,
                                     DECODE (insortexp, 'idescr DESC', idescr) DESC,
                                     DECODE (insortexp, 'idescrl ASC', idescrl) ASC,
                                     DECODE (insortexp, 'idescrl DESC', idescrl) DESC,
                                     DECODE (insortexp, 'iunits ASC', iunits) ASC,
                                     DECODE (insortexp, 'iunits DESC', iunits) DESC,
                                     DECODE (insortexp, 'ispecyr ASC', ispecyr) ASC,
                                     DECODE (insortexp, 'ispecyr DESC', ispecyr) DESc,
                                   SUBSTR (item, 1, 4) || '.' || SUBSTR (item, 5)          -- This is the only non-NULL ORDER BY expression     Why not declare a local variable:
    sortexp      VARCHAR2 (20) := LOWER (insortexp);and use that variable instead of the raw argument in the query:
    ...                              DECODE (sortexp, 'itemnumber asc',  item) ASC,
                                     DECODE (sortexp, 'itemnumber desc', item) DESC, ...Also, this site doesn't like to display the <> operator, even inside \ tags.  When posting here, always use the other inequality operator, !=
    Edited by: Frank Kulash on Jun 15, 2010 3:25 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • The procedure entry point NSSUTIL_EscapeSize could not be located in the dynamic link library nssutil3.dll

    Windows XP with Firefox 18.0.1 wont open when upgraded to latest version.
    Error messages were
    (1) the procedure entry point PR_SetCurrentThreadName could not be located in the dynamic link library ndpr4.dll (2) the procedure entry point NSSUTIL_EscapeSize could not be located in the dynamic link library nssutil3.dll (3) could not load XPCOM
    Ran malware & virus software then removed Firefox via Control panel, then residual folder from Programme files folder and from C:\Documents&Settings\Administrator\Local Folders\ApplicationData\Mozilla.
    Sourced & installed ndpr4.dl and nssutil3.dll - fresh reinstall firefox several times - this got rid of error message 1 but not 2 or 3 and still can't open Firefox.
    Any solutions?

    I have this problem and I am using Zone Alarm Extreme Security with Force Field enabled. I found that by clearing the Virtual Cache in Zone Alarm that this problem went away and was able to run firefox again.
    Here is a post I found that addresses the issue sort of. [http://kb.mozillazine.org/Browser_will_not_start_up#Firefox_does_not_start_after_updating_with_ZoneAlarm_ForceField_enabled http://kb.mozillazine.org/Browser_will_not_start_up#Firefox_does_not_start_after_updating_with_ZoneAlarm_ForceField_enabled]

  • Can we call the procedure which contain commit  in trigger

    can we call the procedure which contain commit in trigger

    Well, what i've noticed from op's past post - whenever op post - he/she posts multiple short questions here. This may be indication of some sort of assignment or any kind of online exam's ...... :?)
    Regards.
    Satyaki De.

  • "The procedure entry point xmlTextReaderName could not be located in the dynamic link library libxml2.dll" fix?

    I have been unable to access the iTunes store for about 3 months and every time I turn on my computer it gives me an error that says "The procedure entry point xmlTextReaderName could not be located in the dynamic link library libxml2.dll" I have tried to find the libxml2.dll file in the Mobile Device Support folder, as suggested by other discussions, but I don't even see an Apple or an Apple Application Support folder when I search my C drive. What can I do to fix this?

    There are 2 places that the Apple Application Support folder might be located, depending on the type of operating system you have - 32 bit or 64 bit. See below
    Now it is also possible that this folder is hidden, which is a default setting in Windows. The way to reveal it is to go to your C:\Program Files folder in Windows Explorer, left click on Tools at the top of Window and select 'Folder Options'.
    Now another Window should open that has 3 headings - General, View, and Search. Select 'View' and scroll down to where it is written 'Hidden Files and Folders', and make sure that SHOW HIDDEN FILES AND FOLDERS is ticked. I'm assuming you have administrator rights. This should now reveal the folders you might not have been finding before. Then follow the instructions below.
    There is also another possibility which I have answered fully in this post
    https://discussions.apple.com/message/16337366#16337366
    I believe that these should get you sorted. Then follow instructions below.
    With Windows Explorer, navigate to your C:\Program Files\Common Files\Apple\Apple Application Support folder.
    Copy the libxml2.dll that you should find there, navigate to the nearby Mobile Device Support folder, and Paste it in there also.
    Restart the programme all should be well
    In case that your OS is (64 bit)
    1. Open windows explorer, go to location C:\Program Files (x86)\Common Files\Apple\Apple Application Support
    2. Copy file "libxml2.dll"
    3. Now paste it in the folder  C:\Program Files (x86)\Common Files\Apple\Mobile Device Support
    4. Restart the programme, it should not display that message, it should be clear.
    Good Luck - Let me know how you do.

  • Itunes will not open on Win 8 saying The Procedure entry point.....

    I had all sorts of issues getting iTunes to run on Windows 8 - but found a solution here somewhere.
    Suddenly today it is giving a massive long error message... The procedure entry point?videoTracks@QTMovie......... could not be located in the dynamic link library C:\Program Files (x86) Common Files \ Apple | Apple Application support \WebKit.dll
    I have repaured, uninstalled, reinstalled, uninstalled, downloaded a new version, installed/.... so far with restarting etc it has taken ages and nothing is changing the status.
    Any ideas anyone please?
    Thank
    Carol

    I know you've already fixed this one, Carol, but for other people reading this post, the following user tip might be useful:
    iTunes for Windows 11.1.4.62: "The procedure entry point: ?videoTracks@QTMovie@ [...] could not be located ..." error messages when launching iTunes

  • AppleSyncNotifier.exe - Entry Point Not Found: The procedure entry point xmlTextReaderConstName could not be located in the dynamic link library libxml2.dll

    Ever since I recently upgrading Itunes, I cannot access the Itunes store, my phone will not sync to my laptop, and this pops up everytime I restart my computer: "AppleSyncNotifier.exe - Entry Point Not Found: The procedure entry point xmlTextReaderConstName could not be located in the dynamic link library libxml2.dll" I have tried several things without success. Can someone PLEASE tell me what else I can try. Thanks!

    Hi Janice - glad to hear you got one of your problems sorted
    I understand that your phone doesn't sync automatically when you connect it to your PC with iTunes running. First question is do you see that your phone is connected in iTunes when you plug it in? It should show on the left side of the page about halfway. Usually if you haven't already started iTunes, when you connect your phone to the PC it will open autoamtically and you will see the phone is connected.
    If it doesn't show as connected then I refer you to this page
    I can tell you that my phone doesn't sync automatically because I didn't want it to, I've purposefully set it on iTunes to sync manually. I do it by left clicking on where my phone shows there and in the page that comes up I click Sync. If you want it to operate automatically then you need to set it to do so. You have that option by clicking on EDIT at the top left of itunes - then PREFERENCES - DEVICES and uncheck 'prevent devices from syncing automatically'. There may also be something to click on the phone page to sync automatically.
    For the 'conflict' issue I refer you to this discussion where others have already offered advice.
    Good luck with it Janice, and again, let me know how you get on.

  • When I allowed an upgrade to Itunes on my HP Windows 7 computer now I have this error message when I turn on my computer:  AppleSyncNotifier.exe-Entry Point Not Found.  The the explanation in the dialogue box says:  The procedure entry point sqlite3_wal_

    Error message after allowing an upgrade:My dialogue box in the error message says:  The procedure entry point sqlite3_wal_checkpoint could not be located in the dynamic link library SQLite3.dll--this happened after I allowed an upgrade to be installed.  I have HP Windows 7.  Now my Iphone will not sync.  What do I do?

    Found this fix here which worked for me with a similar problem.
    https://discussions.apple.com/thread/3196594?start=0&tstart=0
    With Windows Explorer, navigate to your C:\Program Files\Common Files\Apple\Apple Application Support folder.
    Copy the SQLite3.dll that you should find there, navigate to the nearby Mobile Device Support folder, and Paste it in there also.
    Reboot and see if all is well.

  • Calculate the total value of payments with the procedures and triggers?

    Hello!
    I work for a college project and I have a big problem because professor requires to do it by the examples he gives during the lecture. Here's an example that should be applied to its base, so please help!
    I have three table with that should work:
    Invoice (#number_of_invoices, date, comm, total_payment, number_of_customer, number_of_dispatch)
    where:
    number_of_invoices primary key (number),
    date (date),
    comm (var2),
    total_payment is UDT (din - currency in my country) - in this field should be entered value is calculated
    number_of_customer and number_of_dispatch (number) are foreign keys and they are not relevant for this example
    Invoice_items (#serial_number, #number_of_invoices, quantity, pin)
    serial_number primary key (number),
    number_of_invoices primary key (number),
    quantity (number),
    pin foreign keys (number)
    Item (#pin, name, price, tax, price_plus_tax)
    pin primary key (number),
    name (var2),
    price, tax, UDT (din) not relevant for this example
    price_plus_tax UDT (din)
    These are the triggers and procedures with my calculation should be done:
    trigger1:
    CREATE OR REPLACE TRIGGER  "trg1"
    BEFORE INSERT OR UPDATE OR DELETE ON Invoice_items
    FOR EACH ROW
    BEGIN  
         IF (INSERTING OR UPDATING)
         THEN     
              BEGIN Invoice_items.number_of_invoices := :NEW.number_of_invoices; END;
         ELSE
              BEGIN Invoice_items.number_of_invoices :=: OLD.number_of_invoices; END;  
         END IF;
    END;trigger2:
    CREATE OR REPLACE TRIGGER  "trg2"
    AFTER INSERT OR UPDATE OR DELETE ON Invoice_items
    DECLARE
    doc NUMBER := Invoice_items.number_of_invoices;
    BEGIN  
         entire_payment (doc);
    END;procedure
    CREATE OR REPLACE PROCEDURE  "entire_payment" (code_of_doc IN NUMBER) AS 
    entire NUMBER := 0;
    BEGIN 
         SELECT SUM (a.price_plus_tax * i.quantity) INTO entire
         FROM Item a join Invoice_items i on (a.pin = i.pin) 
         WHERE number_of_invoices = code_of_doc;
         UPDATE Invoice
         SET total_payment = entire
         WHERE number_of_invoices = code_of_doc;
    END;As you can see the procedure is called from the triggers, I have a problem at the first trigger, and I think it will be even higher in procedure because UDT, field "total_payment".

    I was not here a few days because I was trying to get additional information related to this problem. Professor gave me the information that I need to introduce a package and variable to get this thing work. But including that I still have problem. I hope that this time is less of a problem and that someone will be able to help me.
    I also noticed that it was not a smart idea to try to translate the names of tables and attributes. That make trouble for me, especially you who are trying to understand and to help me, and absolutely nothing that will change the attribute and the table name will be. So this time I will set out the problem with the original name again to avoid confusion.
    So, I try to base Implement optimization technique called: Repeating Single Detail with Master (so writes the slides that I received from professor, I hope that will mean something to you)
    These are the lines of code that we get on the slides and should implement in the base, again I remind you that at this time in its original form, without translation.
    - First create the package variable:
    create or replace
    package paket
    AS
    sifra number(10):=0;
    end;This part is ok and it works.
    - Secondly, it is necessary to create the first trigger:
    create or replace
    TRIGGER aktuelna_cena1
    BEFORE INSERT OR UPDATE OR DELETE ON cena_artikla
    FOR EACH ROW
    BEGIN
         IF (INSERTING OR UPDATING)
         THEN      
              BEGIN paket.sifra := :NEW.sifra_artikla; END;
         ELSE
              BEGIN paket.sifra := :OLD.sifra_artikla; END;
        END IF;
    END;This part is ok and working.
    Now the problems begin.
    - It is necessary to create another trigger that will call the procedure:
    create or replace
    TRIGGER aktuelna_cena2
    AFTER INSERT OR UPDATE OR DELETE ON cena_artikla
    DECLARE  
         s NUMBER := paket.sifra;
    BEGIN  
         aktuelnacena (s);
    END;I suppose the trigger have problem because procedure is not ok.
    I will copy error that I get from the compiler:
    Error(7,2): PL/SQL: Statement ignored
    Error(7,2): PLS-00905: object NUMBER6.AKTUELNACENA is invalid
    And finally, it is necessary to create the procedure:
    create or replace
    PROCEDURE  aktuelnacena (SifraPro IN NUMBER) AS 
    aktCena artikal.aktuelna_cena%type;
    BEGIN aktCena:=0;
                    SELECT cena INTO aktCena
                    FROM cena_artikla 
                    WHERE sifra_artikla=SifraPro and datum_od=
                                    (select max(datum_od)
                                    from cena_artikla
                                    where sifra_artikla = SifraPro and datum_od<=sysdate); 
                    UPDATE artikal
                    SET aktuelna_cena = aktCena
                    WHERE sifra_artikla = SifraPro;
    END;I will copy error that I get from the compiler:
    Error(10,57): PLS-00103: Encountered the symbol " " when expecting one of the following: ( begin case declare end exception exit for goto if loop mod null pragma raise return select update while with << continue close current delete fetch lock insert open rollback savepoint set sql execute commit forall merge pipe purge The symbol " " was ignored.
    Tables I work with are:
    Artikal (sifra_artikla, naziv, aktuelna_cena),
    Cena_artikla (sifra_artikla, datum_od, cena)
    You will notice that this differs from the first problem, but my task is to implement the two optimization techniques and my base. Both techniques are quite similar and I hope that I now have enough information to help me. I suppose that when this problem is solved the othet one will too!
    Thank in advance!

  • How do I sort out the troubles on the console?

    Gmail - [#SAM-621717]: Trial of home intego          15/03/13 10:59 PM
    [#SAM-621717]: Trial of home intego
    2 messages
    Intego Support <[email protected]> Reply-To: [email protected] To: mlkessell@**** Cc: monicakessell02@****
    Hello Monica,
    Fri, Mar 15, 2013 at 3:52 AM
    If the accounts are on the same computer, you should not have to use a different e-mail address. If your son's account is not an Administrator account, this may be the issue. Are you able to launch VirusBarrier from your son's account from Applications>Intego?
    Kind Regards,
    John Intego Support Team
    ____________________________________________________________________ Intego Technical Support          http://www.intego.com/support
    User manuals are available from the 'Help' menu in all Intego software. Keep up-to-date with the latest Mac security information.
    Visit the Intego Mac Security Blog: http://www.intego.com/mac-security-blog/ Follow us on Twitter: @IntegoSecurity
    Facebook: http://www.fa****.com/Intego ____________________________________________________________________
    Monica Kessell <monicakessell02@****>          Fri, Mar 15, 2013 at 10:55 PM To: [email protected]
    Yes I am able to do that and the issue that we were having seems to have settled down after the computer crashed and I restarted it by resetting PRAM and repairing the disk. Can you help me understand what to do about the issues that the console in utilities is logging frequently? both before and since the crash yesterday; (see below)
    First issue; An instance 0x10062c110 of class CBX5KeyboardObservationController was deallocated while key value observers were still registered with it. Observation info was leaked, and may even become mistakenly attacked to some other object. set a breakpoint on NSKVODeallocateBreak to stop here in the debugger. Here's the current observation info: .......
    (lots of stuff I don't understand)
    Monica Kessell <monicakessell02@****>
    Gmail - [#SAM-621717]: Trial of home intego          15/03/13 10:59 PM
    Second Issue; barrier.daemon[51] launcht l: Error unloading:com.intego.virusbarrier.bm_controller barrier.daemon[51] launcht l: Error unloading:com.intego.virusbarrier.bm_injector_32 barrier.daemon[51] launcht l: Error unloading:com.intego.virusbarrier.bm_injector_64 com.apple.launchd[1] (com.apple.xprotectupdater[25]Exited with exit code:252 e.WindowServer[95]Fri Mar 15 21:54;39 monica-kessellsimac. local WindowSever[95] <Error>: kCGErrorFailure: set a breakpoint @ CGErrorBreakpoint() to catcherrors as they are logged. d.peruser .501[146] (com.apple.ReportCrash) Falling back to default Mach exception handler. Could not find: com.apple ReportCrash.Self d.peruser .501[146]          (com.apple.mrt.uiagent[178])Exited with exit code 255 tions.enabled[186] launchct l : CFURLWriteDataAndPropertiesToResource(/var/db/launchd.db/ com.apple.launchd.peruser.501/overides.plist) failed:-10 d.peruser.501[146] (com.apple.Kerberos.renew.plist[179]) Exited with exit code: 1 tions.enabled[186] launchct l : CFURLWriteDataAndPropertiesToResource(/var/db/launchd.db/ com.apple.launchd.peruser.501/overides.plist) failed:-10 es.integomenu[185] objc[185]:ClassIFCrossCompatibleUnicodeString is implemented in both /Library/Intego/Family Protector.bundle/Contents/MacOS/Family Protector Daemon.app/Contents/ Frameworks/Family Protector Foundation.framework/Versions/A/Family ProtectorFoundation and /Library/Intego/ personalbackupd.bundle/Contents/MacOS/Personal BackupDaemon.app/Contents/ Frameworkds/PersonalBackup.framework/Versions/A/PersonalBackup. One of the two will be used. Which one is undefined
    and there are more messages like this regarding the Class IFTimeIntervalManager and the Class IFUUID and the Class IFMessanger and the Class IFMessangerClient and the class IFMessangerLion and the class IFMDelayed Messange and the Class IFSnowReply and the Class IFMessagerSnow and the Class IFMessanger and the Class IFMLionReply
    and on and on the messages go
    Can you shed some light on the subject and help me sort out the computer?
    regards
    Monica Kessell
    <Emails Edited By Host>

    Here's my latest list of complaints to Intego regarding Family Protector. I thought it should be shared:
    I have been using Family Barrier for a couple of years now, and may I say, it has so many problems that as soon as I can find a better alternative, I'm gone. Until that day, however, I expect some solutions.
    Issue #1: The application is 100% unreliable. The chances of it doing its job on any given day are seriously 50/50. Or worse. This alone renders the program useless. But that's not all.
    Issue #2: It's unbelievably easy to override. Are you seriously unaware that all one has to do is change the date on the computer to one before Family Barrier was installed, it will 100% not do its job. Awesome. This is straight out of Hacking 101, and any program should be able to defend against it. Otherwise, any demo I try download can be made to work forever. While some are, most are not. Get it together, People.
    Of course, making time changes impossible can be done from my end by the keeping admin password unknown to the protected user, but what if the protected user needs admin access? That happens to be my case. Nonetheless, I was willing to block admin access to fix the problem until you could tell me that YOU'VE done your job and taken care of it (you will tell me that, right?). But then I was left with Issue #1 (remember? the one where it only works 50% of the time at best?), so what's the point?
    I thought I'd try reinstalling it again, just for fun. I've done this before and it's worked TEMPORARILY (tell me the truth, would you pay for an application that constantly had to be re-installed so that it would work for a while? the truth, now). Why am I not surprised that now even that simple process is f'ing up. I punch in my name and serial and it won't accept it. Is there no end to the awesomeness? Somehow, I think that there is not.
    It's especially frustrating that there is no support number for me to call, forcing me to have to go through THIS process, which makes your job so much easier and is so much less helpful for your customers) just to get any answers... eventually.

  • Firedox did a restart, now it wont open i get the message The procedure point js_UnwrapObjectAndInnerize could not be located in the dynamic link library

    firefox did a restart now it wont open, i get the following message,
    The procedure point js_UnwrapObjectAndInnerize could not be located in the dynamic link library
    have tried system restore but this didnt help

    Do a clean reinstall and delete the Firefox program folder (C:\Program Files\Mozilla Firefox\) before reinstalling a fresh copy of Firefox.
    *http://kb.mozillazine.org/Installation_directory
    Download a fresh Firefox copy and save the file to the desktop.
    *Firefox 15.0.x: http://www.mozilla.org/en-US/firefox/all.html
    Uninstall your current Firefox version, if possible, to cleanup the Windows registry and settings in security software.
    *Do NOT remove personal data when you uninstall your current Firefox version, because all profile folders will be removed and you will also lose your personal data like bookmarks and passwords from profiles of other Firefox versions.
    Remove the Firefox program folder before installing that newly downloaded copy of the Firefox installer.
    *It is important to delete the Firefox program folder to remove all the files and make sure that there are no problems with files that were leftover after uninstalling.
    *http://kb.mozillazine.org/Uninstalling_Firefox
    Your bookmarks and other profile data are stored in the Firefox Profile Folder and won't be affected by an uninstall and (re)install, but make sure that "remove personal data" is NOT selected when you uninstall Firefox.
    *http://kb.mozillazine.org/Profile_folder_-_Firefox
    *http://kb.mozillazine.org/Profile_backup
    *http://kb.mozillazine.org/Standard_diagnostic_-_Firefox#Clean_reinstall

  • How do I get itunes to sort songs the same way my ipod does, without renaming the songs?

    Itunes and my ipod use different algorithms when sorting songs.  Here are a few examples:
    In itunes, apostrophes come before spaces/other characters  ("It's Good to Be King" comes before "It Keeps You Runnin'" and "You're an Original" comes before "You Better You Bet."  In my ipod, apostrophes come after spaces/other characters.
    In itunes, numerical song titles are sorted by the first number, then the second, and so on (18, 1983, 2112, 25, 3).  In my ipod, numerical song titles are sorted in ascending numerical order (3, 18, 25, 1983, 2112).
    The order is relevant for two reasons.  One, I like the sound of the song flow generated by my ipod's sorting better than the one generated by itunes.  Two, I use play count to determine whether or not to keep a song on my playlist (songs that I skip over repeatedly get cut entirely) and the changing song order tends to mess up the play count.
    So, other than going in and changing the names of the songs, is there some way to make itunes behave like my ipod?

    I deal with the numeric ordering by padding out the sort fields with leading zeros. iTunes used to sort numbers by value but it seems the code for that got removed at some point and hasn't been replaced. You should be able to use sort values to achieve some consistency between the two views of your media.
    See also Grouping tracks into albums.
    tt2

  • Pass a value to the procedure from jsp

    Hi I need a help..
    I have a jsp page which has the value , And I have one stored procedure in a java file. I have to pass this
    selected month to that stored procedure. there are 2 input parameters and one out parameter which returns a date files. If i hard code the input parameters i am able to get the date field. the first parameter is in session, that is divisionCode. So no problem with that... but other value the selectedMoth "12/2003" should be passed from the jsp.
    help me how to achive this....
    my jsp code is
    <%
    String selectedMonth = request.getParameter("selectedMonth");
    String monthLastDate = callPLSQLFunc.getmonthLastDate(divisionCode);
    System.out.println("Month Last date is " +monthLastDate);
    %>my calling procedure
    public String monthLastDate(String divisionCode, String selectedMonth) {
            CallableStatement stmt = null;
            ResultSet rs=null;
            String lastDate ="";
          try {
              System.out.println("calling the procedure for month end date");
           //  stmt = con.prepareCall ("{?= call easmsa_front_end_routines_pkg.get_month_end_date(?,?)}");
             System.out.println("calling the procedure for month end date");
            stmt = con.prepareCall("begin easmsa_front_end_routines_pkg.get_month_end_date_prc(?,?,?); end;");
            stmt.setString(1,divisionCode);
            System.out.println("division Code is " +divisionCode);
            System.out.println("The last_date 1 ");
           //  stmt.registerOutParameter(2, oracle.jdbc.OracleTypes.VARCHAR);
             stmt.setString(2,selectedMonth);
             System.out.println("The last_date 2 " +selectedMonth);
             stmt.registerOutParameter(3, oracle.jdbc.OracleTypes.DATE);
             System.out.println("The last_date 3 ");
             stmt.execute();
             System.out.println("getting the value");
         //    lastDate = stmt.getDate(3);
             System.out.println(stmt.getDate(3));
        //     System.out.println("The last_date " +lastDate);
            } catch (SQLException e) {
                e.printStackTrace();
            return lastDate;
        public String getmonthLastDate(String divisionCode,String selectedMonth){
            String monthLastDate = monthLastDate(divisionCode,selectedMonth);
            return monthLastDate;

    Well, you'd just pass the parameter ....
    String monthLastDate = callPLSQLFun.getmonthLstDate(divisionCode, selectedMonth);
    [/code[
    ... or am I totall misunderstanding your question??
    Also, you have two methods which are public, and all one does is call the other with exactly the same parameters passed.  Why not just call monthLastDate() instead of getmonthLastDate() ... it does exactly th same thing, only without the extra call.
    I think maybe you need to grasp the basics of Java a little better before delving into the world of JSP.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • What does this message mean on my PC " the procedure entry point sqlite3_wal_checkpoint could not be located in dynamic link library SQlite3.dll.

    Why does this message pop up on my PC after i start up " (AppleSyncNotifier.exe-Entry Point Not Found ) the procedure entry point sqlite3_wal_checkpoint could not be located in dynamic link library SQlite3.dll. ? What can I do to fix this problem ?

    Found this several months ago when I updated ITunes. I don't know why they still haven't fixed this, but I had to do this again yesterday 10/13/2011 when I updated.
    With Windows Explorer, navigate to your C:\Program Files\Common Files\Apple\Apple Application Support folder.
    Copy the SQLite3.dll that you should find there, navigate to the nearby Mobile Device Support folder, and Paste it in there also.
    Reboot and see if all is well
    In case that your OS is Windows 7 (64 bit)
    1. Open windows explorer, go to location C:\Program Files (x86)\Common Files\Apple\Apple Application Support
    2. Copy file "SQLite3.dll"
    3. Open new windows explorer, to to location C:\Program Files (x86)\Common Files\Apple\Mobile Device Support
    4. Paste file "SQLite3.dll" to the location.
    5. Reboot your computer, it should not display that message, it should be clear.

  • What do I do when I try to open Fifrefox 4 & get the message: The procedure entry point NS_SetDllDirectory could not be located in the dynamic link library xul.dll?

    2 days ago, I got a message about upgrading to Firefox 4.0. I didn't do it immediately, due to lack of time. Later that day, I tried to open Firfox & got the message: Firefox can't start because xul.dll is missing. Reinstall the program to fix this. I tried several times to open Firefox & got the same result. I tried rebooting. Same result. So I opened Internet Explorer & went to the Firefox website & followed the instructions to download Firefox 4. After that, I used it last night & left my laptop hibernating last night, then continued to use it this morning. Then I closed Firefox. When I next tried to reopen Firefox, I got the new message: The procedure entry point NS_SetDllDirectory could not be located in the dynamic link library xul.dll. Again, I can only access the internet with Internet Explorer. Also, I have a done a good many Windows updates over the last 2 days as well. What can I do to get Firefox to open? Thank you for your help.

    This is what I did to resolve this problem. First, I uninstalled Firefox 4 & removed the Firefox folder left behind. I made sure to NOT select the option to delete personal information. Next, I backed up all of the important files on my computer. Next, I upgraded my Windows 7 to Service Pack 1, which was pending in my updates folder. Then, I went to Mozilla's website & downloaded Firefox 4 again, making sure to select only the Firefox browser and not Thunderbird too. http://www.mozilla.org/ When prompted to close any open programs, I closed Internet Explorer (which I had used to get to the Mozilla website) and I disabled my Norton anti-virus. I then completed the installation & it works just fine now. It loaded all of my personal data, such as bookmarks, it remembered my password, etc. It's fine for my needs, as I'm not a heavy user of special add-ons & plug-ins. Some of those may not work yet with the new version.

Maybe you are looking for

  • How to enable excel downloading in ALV grid report.

    Hi all, How to enable excal downing in ALV grid report? Thanks in Advance. Siva Sankar.

  • How to use excel api in java?

    I need to use excel api in Java to generate data in excel format. Can any one tell any of the use ful Excel api that we can down load from net? i have read about Apache's POi-hssf-Java api. But the jar i downloaaded from Apache site is not working ?

  • I need help disentangling gmail and Thunderbird

    The article "Thunderbird and Gmail" would be very helpful if I were setting up my email from the beginning. but I set it up a long time ago and I need help straightening things out. The folders at the left hand side of the Thunderbird screen are very

  • SWF keeps playing in the Background

    Hello, I am using a Flash based course player (AS3) to play SWF slides, both from Flash and Captivate. My problem is that when I click Next when viewing a Captivate SWF, I can hear the audio overlapping when on the next slide (if I clicked next witho

  • HT1688 The new do not disturb (DND) feature is not working.

    The new DND feature is not working; tested all the variables of the feature, but phone calls were able to come thru, although the choice was set not to receive calls from no one. Any fix as yet?