User Profile

Collapse

Profile Sidebar

Collapse
Beeb
Beeb
Last Activity: Apr 8 '13, 12:28 AM
Joined: May 16 '10
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Beeb
    replied to Using exception handling in a Loop w/ Cursor
    Never mind I figured it out. Here's my code incase anyone has the same question
    Code:
    DECLARE
      CURSOR orderlist IS
        SELECT distinct inv_id, b.item_id, item_desc, inv_price
        FROM inventory a, item b
        WHERE a.item_id=b.item_id AND b.item_id=1
        ORDER BY inv_id;
      output orderlist%ROWTYPE;
      error EXCEPTION;
    BEGIN
      OPEN orderlist;
      LOOP
        FETCH orderlist INTO output;
    ...
    See more | Go to post

    Leave a comment:


  • Beeb
    started a topic Using exception handling in a Loop w/ Cursor

    Using exception handling in a Loop w/ Cursor

    I'm trying to use an exception handler when the select statement tries to access an invalid item_id. I tried and with this code, it runs but throws nothing. I later found out that cursor will make it run regards if no rows are returned.
    Code:
    DECLARE
      CURSOR orderlist IS
        SELECT distinct inv_id, b.item_id, item_desc, inv_price
        FROM inventory a, item b
        WHERE a.item_id=b.item_id AND b.item_id=10
        ORDER
    ...
    See more | Go to post

  • my thread is updated
    See more | Go to post

    Leave a comment:


  • Help with javascript to end a while loop by a letter

    How do I get the program to end entering "q". Here's what I've done so far:

    Code:
    <script type = "text/javascript">
    
    function assignFirstClass( first )
    {
    	alert ( "You are assigned seat " +  + " in first class" )
    }
    
    function assignCoach ( coach )
    {
    	alert ( "You are assigned seat " +  + " in first class"
    ...
    See more | Go to post
No activity results to display
Show More
Working...