How do I get rid of this sql warning?

Hi folks,
I am running oracle 10.2.0 on Linux. I would like to get rid of this sql code warning
(Warning(151,3): PLW-07202: bind type would result in conversion away from column type)I get when I compile the code below. Basically Oracle does not like the idea of using a number in an expression with sysdate. eg (sampling_date < sysdate - p_n_value) where p_n_value is a number;
What is the best way to do this?
CREATE TABLE "USERDATA"."TBL_SESSION_SQL_WAIT_HISTORY"
   (           "SESSION_SQL_WAIT_HIST_SEQ_ID" NUMBER,
                "DBID" NUMBER,
                "SID" NUMBER,
                "SEQ#" NUMBER,
                "EVENT" VARCHAR2(64 BYTE),
                "P1TEXT" VARCHAR2(64 BYTE),
                "P1" NUMBER,
                "P1RAW" RAW(8),
                "P2TEXT" VARCHAR2(64 BYTE),
                "P2" NUMBER,
                "P2RAW" RAW(8),
                "P3TEXT" VARCHAR2(64 BYTE),
                "P3" NUMBER,
                "P3RAW" RAW(8),
                "WAIT_TIME" NUMBER,
                "SECONDS_IN_WAIT" NUMBER,
                "STATE" VARCHAR2(19 BYTE),
                "SAMPLING_DATE" DATE,
                "SAMPLING_TIME" VARCHAR2(8 BYTE),
                "SERIAL#" NUMBER,
                "USERNAME" VARCHAR2(30 BYTE),
                "OSUSER" VARCHAR2(30 BYTE),
                "PADDR" RAW(4),
                "LOGON_TIME" DATE,
                "PROCESS" VARCHAR2(24 BYTE),
                "SQL_HASH_VALUE" NUMBER,
                "SADDR" RAW(4),
                "MODULE" VARCHAR2(48 BYTE),
                "ROW_WAIT_OBJ#" NUMBER,
                "ROW_WAIT_FILE#" NUMBER,
                "ROW_WAIT_BLOCK#" NUMBER,
                "ROW_WAIT_ROW#" NUMBER
   ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
  STORAGE(INITIAL 16384 NEXT 65536 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
  TABLESPACE "USERDATA" ;
  CREATE TABLE "USERDATA"."TBL_SQLTEXT_WAIT_HISTORY"
   (           "SQLTEXT_SEQ_ID" NUMBER,
                "DBID" NUMBER,
                "ADDRESS" RAW(4),
                "HASH_VALUE" NUMBER,
                "SQL_ID" VARCHAR2(13 BYTE),
                "COMMAND_TYPE" NUMBER,
                "PIECE" NUMBER,
                "SQL_TEXT_PIECE" VARCHAR2(64 BYTE),
                "SQL_TEXT" VARCHAR2(1000 BYTE),
                "DISK_READS" NUMBER,
                "BUFFER_GETS" NUMBER,
                "DIRECT_WRITES" NUMBER,
                "PARSE_CALLS" NUMBER
   ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
  STORAGE(INITIAL 16384 NEXT 65536 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
  TABLESPACE "USERDATA" ;
create or replace
PROCEDURE data_coll AS
p_n_value userdata.tbl_options.n_value%type;  -- number
BEGIN
-- irrelevant code here
  select n_value into p_n_value from tbl_options where name ='PURGE_DAY_COUNT';
  DELETE FROM tbl_sqltext_wait_history t where t.hash_value in
    (select s.sql_hash_value from cc_session_sql_wait_history s
    where s.sampling_date < sysdate  - p_n_value
    and s.sql_hash_value = t.hash_value);
  DELETE FROM tbl_session_sql_wait_history
  WHERE sampling_date < sysdate - p_n_value;
END;Thanks in advance for your feedback.
rgds, Efachim
Edited by: efachim on Jan 19, 2009 10:44 AM

One general suggestion.
"TBL_SESSION_SQL_WAIT_HISTORY"Did you create your table and column names within double quotes?
It will make your table as case sensitive.
Regards.
Satyaki De.

Similar Messages

  • How can I get rid of this security warning for files on CD?  Usual answers not working.

    Hi all,
    I have Acrobat X Pro patched to 10.1.8 on Windows 7.  I am trying to create and use a CD with a set of hyperlinked PDFs on it.
    Whenever I click a link in any of the PDFs, the attached security dialog comes up.  The box being ticked doesn't matter, Acrobat doesn't add anything to its list of websites in Trust Manager.  I have added D:\ to the list of privileged locations in the enhanced security preferences.  In fact, I have tried turning off enhanced security altogether, and even that didn't work.  I have also tried both "Allow access to all websites / Default behavior:  Allow Access" (which irritatingly reverted to "Allow access / Always ask" BTW) and "Custom / Default behavior: Always Ask" in the Manage Internet Access preferences under Trust Manager.  Trust Manager won't let you add local paths.
    I can change the PDF files too if it's something to do with the type of hyperlink between them.  They're relative links to other files in the same directory created using Word and then converted to PDF with Acrobat PDFMaker.
    Thanks
    Drew

    It's possible that the file that any path points to may be changed, but it appears Acrobat happily accepts those other paths.
    If that is really intended behavior as built, is there a way to fool Acrobat that a given disc isn't removable media?

  • HT4623 I have an download that hasnt downloaded and my phone keeps asking me to put my apple id password in how do it get rid of this?

    I have an download that hasnt downloaded and my phone keeps asking me to put my apple id password in how do it get rid of this?

    Any error message?

  • In Mail, one mailbox for Recovered Message (AOL) keeps showing 1 very large message that I cannot delete. How can I get rid of this recurring problem, please?

    In Mail on iMac, successfully running OS X Lion, one mailbox on My Mac for "Recovered Messages (from AOL)" keeps showing 1 very large message (more than 20 Mb) that I just cannot seem to delete. Each time I go into my In Box, the "loading" symbol spins and the message appears in the "Recovered Messages" mailbox. How can I get rid of this recurrent file, please?
    At the same time, I'm not receviving any new mails in my In Box, although, if I look at the same account on my MacBook Pro, I can indeed see the incoming mails (but on that machine I do not have the "recovery" problem).
    The help of a clear-thinking Apple fan would be greatly appreciated.
    Many thanks.
    From Ian in Paris, France

    Ian
    I worked it out.
    Unhide your hidden files ( I used a widget from http://www.apple.com/downloads/dashboard/developer/hiddenfiles.html)
    Go to your HD.
    Go to Users.
    Go to your House (home)
    there should be a hidden Library folder there (it will be transparent)
    Go to Mail in this folder
    The next folder ( for me ) is V2
    Click on that and the next one will be a whole list of your mail servers, and one folder called Mailboxes
    Click on that and there should be a folder called recovered messages (server) . mbox
    Click on that there a random numbered/lettered folder -> data
    In that data folder is a list of random numbered folders (i.e a folder called 2, one called 9 etc) and in EACH of these, another numbered folder, and then a folder called messages.
    In the messages folder delete all of the ebmx (I think that's what they were from memory, sorry I forgot as I already deleted my trash after my golden moment).
    This was GOLDEN for me. Reason being, when I went to delete my "recovered file" in mail, it would give me an error message " cannot delete 2500 files". I knew it was only 1 file so this was weird. Why 2500 files? Because if you click on the ebmx files like I did, hey presto, it turned out that they were ALL THE SAME MESSAGE = 2500 times. In each of those folders in the random numbers, in their related message folder.
    Now remember - DONT delete the folder, make sure you have gone to the message folder, found all those pesky ebmx files and deleted THOSE, not the folder.
    It worked for me. No restarting or anything. And recovered file. GONE.
    Started receiving and syncing mail again. Woohoo.
    Best wishes.

  • The curser includes a text box from a previous image or link when the curser is positioned on the side of the page. i click and it goes away but only to return again on the next launched page. how do i get rid of this?

    the cursor includes a text box from a previous image or link when the cursor is positioned on the side of the page. it will mainly happen when i hit "back" from the page i was on. i click and it goes away but only to return again on the next launched page. i also keep several tabs open and it will carry over to any one of them i go to. how do i get rid of this?
    == This happened ==
    Every time Firefox opened
    == when i upgraded to most recent version 3.6.8

    A number of extensions can cause that problem, you'll need to do a little troubleshooting to find out which extension is causing that to happen for you.
    [http://support.mozilla.com/en-US/kb/troubleshooting+extensions+and+themes]

  • Hi! I sold my Iphone on ebay. The seller wants to connect the Iphone with his Apple ID, but it did not work because it says that the Iphone is already connected with another Apple ID. How can I get rid of this old connection? What do I have to do?

    Hi! I sold my Iphone on ebay. The seller wants to connect the Iphone with his Apple ID, but it did not work because it says that the Iphone is already connected with another Apple ID. How can I get rid of this old connection? What do I have to do?

    What to do before selling or giving away your iPhone, iPad, or iPod touch
    http://support.apple.com/kb/HT5661
    MaggySimpson wrote:
    Hi! I sold my Iphone on ebay.
    Follow the instructions to remove a device you no longer have.
    From here  >  http://support.apple.com/kb/PH13695?viewlocale=en_US

  • I get a recurrent request to connect by wi-fi to another computer on my wi-fi network, even if I am already connected to this other computer by wi-fi.  How do I get rid of this recurrent request?

    I have two MacBook Pros on my local wi-fi network.  I usually have these connected to each other over my wi-fi network.  Normally, I only connect to my old computer (MacBookPro) from the new computer (MacBookPro2), so I can access files on my old computer that are typically not on my new computer.  I use the same admin username (John Doe) and password on each computer.  Currently, I have Mavericks (10.9.5) on my old computer and Yosemite (10.10) on the new MacBook Pro.  All
    I am now getting a recurrent request to connect to old computer even when I am already connected!  When this request is being made, I am asked to connect to a username (johndoe instead of John Doe).  The exact alert:
         Enter your name and password for the server "MacBook Pro".
         connect as     << button is pressed for Registered User >>
         Name: johndoe
         Password: _________
         << Cancel button >>  << Connect button >>
    When I enter correct user name (John Doe or johndoe) and password for my account on Mavericks computer, the connection fails (whether I connected to Mavericks computer or not), and I get the following:
         There was a problem connecting to the server "MacBookPro".  The share does not exist on the server.  Please check the share name and try again. 
    If I change to the proper share name John Doe and use the correct password, I still am not connected and I get the same failure message and am asked to use the correct share name again.  If I cancel message, the connection message goes away for a while whether I am actually connected to old computer or not. It will then come back on the workspace I am currently using on my new macbook.  When I am downloading files using terminal, the connect request comes up constantly if I continue canceling the message which is really irritating.  How do I get rid of this constantly recurring request to connect???

    It means you must be connected to your computer via Wi-Fi (or cable).
    Or wait for iOS 5

  • I'm using 9.2.1.  Every time I open an album, I get a "face (the same one)" covering every picture. If I click on the picture, I can see the real picture.  How do I get rid of this "face" that covers all?

    I'm usingiPhoto 9.2.1.  Recently, everytime I open an album, I get a "face (the same one)" covering every picture. If I click on the picture, I can see the real picture.  How do I get rid of this "face" that covers all?

    Make a temporary backup of your library (if you don't already have a backup of it) and launch iPhoto with the Command +Option key held down and rebuild the library with options #1, 2, 3 and 6 selected.
    OT

  • A black airplay info window floats around on my HDTV screen when sending audio content via airplay up to sound system w Apple TV.  How can I get rid of this?

    A black airplay info window floats around on my HDTV screen when sending audio content via airplay up to sound system w Apple TV.  How can I get rid of this?

    Had this happen to me after a recent update, was super annoying.  To turn off, go to Settings > AirPlay > Conference Room Display > Off.

  • Hi everyone,,i bought a used iphone 5 with iOs 7.0.3. i want to delete the icloud account and add mine. I have sent an e-mail to the current account being used in my iphone. How can i get rid of this account plzzz help me out

    Hi everyone,,i bought a used iphone 5 with iOs 7.0.3. i want to delete the icloud account and add mine. I have sent an e-mail to the current account being used in my iphone. How can i get rid of this account plzzz help me ou

    no i called the store owner from whom i bought it. he was like i will check in records and if there is something i will let u know...he was like send an e-mail its better so if it was stolen so the shopkeeper wouldnt let me to e-mail to the owner

  • When you open a new browser tab, underneath the box to type in what you are looking for is the recently visited list. I want to disable or delete this list...how do I get rid of this list???

    When you open a new browser tab, underneath the box to type in what you are looking for is the recently visited list. I want to disable or delete this list...how do I get rid of this list???

    The drop-down list displays items from your History and/or Bookmarks.
    You can control what shows (or nothing at all): Options > Privacy, "Location Bar" section. Options are:
    *History and Bookmarks
    *History
    *Bookmarks
    *Nothing
    See --> https://support.mozilla.com/en-US/kb/Options%20window%20-%20Privacy%20panel
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''
    Not related to your question, but...
    You may need to update some plug-ins. Check your plug-ins and update as necessary:
    *Plug-in check --> http://www.mozilla.org/en-US/plugincheck/
    *Adobe Shockwave for Director Netscape plug-in: [https://support.mozilla.com/en-US/kb/Using%20the%20Shockwave%20plugin%20with%20Firefox#w_installing-shockwave Installing ('''''or Updating''''') the Shockwave plugin with Firefox]
    *Adobe PDF Plug-In For Firefox and Netscape: [https://support.mozilla.com/en-US/kb/Using%20the%20Adobe%20Reader%20plugin%20with%20Firefox#w_installing-and-updating-adobe-reader Installing/Updating Adobe Reader in Firefox]
    *Shockwave Flash (Adobe Flash or Flash): [https://support.mozilla.com/en-US/kb/Managing%20the%20Flash%20plugin#w_updating-flash Updating Flash in Firefox]
    *Next Generation Java Plug-in for Mozilla browsers: [https://support.mozilla.com/en-US/kb/Using%20the%20Java%20plugin%20with%20Firefox#w_installing-or-updating-java Installing or Updating Java in Firefox]

  • My 'backup' is taking up a huge space on my hard drive but I have an external hard drive for my back ups - how do i get rid of this?

    Please can you help - I have recently added an external hard drive to my Macbook so it can be used as a back up and storage to save space on my hard drive.  I have deleted videos and photos from my hard drive but they are being replaced with 'backup'
    how do i get rid of this ?
    thanks

    Welcome to Apple Support Communities
    Time Machine makes local snapshots in all portable Macs with Lion or Mountain Lion. They are made in the internal drive and they are removed when your hard disk gets full, so you don't have to worry about it.
    If you want to delete them, turn off Time Machine and turn it on every time you want to make a backup. You can also turn them off manually without having to turn off Time Machine, or you can delete those local snapshots > http://pondini.org/TM/30.html

  • AFter the latest download, my e-mail service keeps getting a bar at the top "Firefox prevented this page from automatically redirecting to another page". I have to keep hitting the "Allow" link? How do I get rid of this?

    Ever since the last update, I'm having problem accessing my e-mail account. I keep getting an annoying bar at the top of the screen "Firebox prevented this page from automatically redirecting to another page." I have to keep hitting the allow button, sometimes twice. And when I do get into the accounts the bar jumps in and out every time I open a new e-mail, or delete and old one.
    How do I get rid of this. I've had this account for years, with a very reputable private e-mail provider. This is nuts.

    See:
    *Firefox/Tools > Options > Advanced > General : Accessibility : [ ] "Warn me when web sites try to redirect or reload the page"
    The setting in "Tools > Options > Advanced > General" is meant as an accessibility feature, as you can see by the label of that section, so that people with disabilities or people who use screen readers do not get confused and is not meant as a safety protection to stop redirecting.
    See also:
    *https://support.mozilla.com/kb/Options+window+-+Advanced+panel#General_tab
    *http://kb.mozillazine.org/accessibility.blockautorefresh
    *http://kb.mozillazine.org/Accessibility_features_of_Firefox

  • Messages icon indicates that there is an unopened message but when i go into it the message is blank and no option to delete it. Any ideas how i can get rid of this and stop it from opening up in the blank message each time i open my messages?

    The message icon on my iphone indicates that there is an unopened text message, but when i go into it, it just opens up a blank message, and there is no option to delete it. Any suggestions how i can get rid of this message, and prevent my phone from always opening up in the blank message whenever i go into my messages, rather than just opening as my inbox?
    Many thanks

    Hard restart..  While the phone is powered in, hold the power and home button.   Hold them down and keep them held down.  the phone will eventually shut itself off and reopen.  keep held down till you see the appl elogo, then release.  This will not delete anything off your phone, it will just force all apps to stop their current process.  If you just turn the phone on and off, it will just pick up where it left off.  Good luck

  • TS3230 i get a pop-up window saying the current version of Safari does not support the community toolbar.  How do I get rid of this?

    i get a pop-up window saying the current version of Safari does not support the community toolbar.  How do I get rid of this?

    You need to uninstall the Community / Conduit toolbar add-on.
    Locate the files in bold print and move them to the Trash. The first five are in your root   /Library
    /Library/Application Support/Conduit
    /Library/InputManagers/CTLoader
    /Library/ScriptingAddtions (anything CTLoader realted)
    /Library/Receipts/<Toolbar name>.pkg
    /Library/Application Support/SIMBL/Plugins/CT2285220.bundle
    The next one is in your Home folder.
    ~/Library/Application Support/Conduit
    When you're done, try Safari.

Maybe you are looking for