E-mail, File

Hi Guys,
I am new to UTL_FILE, UTL_SMTP. I am using system user account. I wrote two stored procedures using them. Compilation is OK. But when I execute I have following error:
SQL> CREATE OR REPLACE PROCEDURE write_file AS
2 lft_file_hdle UTL_FILE.FILE_TYPE;
3 ls_bfr_line VARCHAR2(1000);
4 ls_file_path VARCHAR2(75) := 'c:\';
5 ls_file_name VARCHAR2(75) := 'Results_';
6
7 Begin
8 ls_file_name := ls_file_name| |to_char(sysdate, 'dd-mm-yyyy')| |'.txt';
9 lft_file_hdle := UTL_FILE.FOPEN(ls_file_path, ls_file_name, 'W');
10 UTL_FILE.PUT_LINE(lft_file_hdle, 'abc');
11 UTL_FILE.FCLOSE(lft_file_hdle);
12 End;
13 /
Procedure created.
SQL> exec write_file
BEGIN write_file; END;
ERROR at line 1:
ORA-06510: PL/SQL: unhandled user-defined exception
ORA-06512: at "SYS.UTL_FILE", line 98
ORA-06512: at "SYS.UTL_FILE", line 157
ORA-06512: at "SYSTEM.WRITE_FILE", line 9
ORA-06512: at line 1
CREATE OR REPLACE PROCEDURE sp_tag_alert_mail (
in_sender IN VARCHAR2,
in_recipient IN VARCHAR2,
in_subject IN VARCHAR2,
in_message IN VARCHAR2)
IS
ls_mailhost VARCHAR2(30) := '10.25.2.175'; --'ROEDINGHSN01';
lm_mail_conn utl_smtp.connection;
ls_test VARCHAR2(100);
ls_crlf VARCHAR2(2):= CHR(13)| |CHR(10);
ls_msg VARCHAR2(800);
BEGIN
lm_mail_conn := utl_smtp.open_connection(ls_mailhost, 25);
utl_smtp.helo(lm_mail_conn, ls_mailhost);
utl_smtp.mail(lm_mail_conn, in_sender);
utl_smtp.rcpt(lm_mail_conn, in_recipient);
ls_msg:= 'Date: ' | |TO_CHAR(SYSDATE, 'dd Mon yy hh24:mi:ss')| |ls_crlf| |
'From: ' | |in_sender| |ls_crlf| |
'To: ' | |in_recipient| |ls_crlf| |
'Subject: '| |in_subject| |ls_crlf;
ls_msg:= ls_msg | |' '| |ls_crlf| |in_message| |'.'| |ls_crlf;
UTL_SMTP.OPEN_DATA(lm_mail_conn);
UTL_SMTP.WRITE_DATA(lm_mail_conn, ls_msg);
UTL_SMTP.WRITE_DATA(lm_mail_conn, ls_msg);
UTL_SMTP.CLOSE_DATA(lm_mail_conn);
UTL_SMTP.QUIT(lm_mail_conn);
END;
SQL> sho err
No errors.
SQL> exec sp_tag_alert_mail('[email protected]','[email protected]','Test','Testing');
BEGIN sp_tag_alert_mail('[email protected]','[email protected]','Test','Testing'); END;
ERROR at line 1:
ORA-20001: 421 Service not available
ORA-06512: at "SYS.UTL_SMTP", line 83
ORA-06512: at "SYS.UTL_SMTP", line 121
ORA-06512: at "SYSTEM.SP_TAG_ALERT_MAIL", line 17
ORA-06512: at line 1
is there anything wrong with my code.
please help me.
Thanks in anticipation
r@m@
Note: - I doubt that i dont have privilege to use this package... am I correct.

Hi ahmadhfz,
Are you receiving a winmail.dat file attached to your email messages?  If so, take a look at the following article to see if it helps.
KB03820 - A winmail.dat file is attached to a received email message instead of the original attachm...
Thanks.
-CptS
Come follow your BlackBerry Technical Team on twitter! @BlackBerryHelp
Be sure to click Kudos! for those who have helped you.Click Solution? for posts that have solved your issue(s)!

Similar Messages

  • How do I know if time machine is backing up my apple mail? I need to have copies of all of my emails, so there I have a lot of mail files. I was told that if I change computers, that the mail files will all be on time machine. Is this true? Thanks, Dave

    Is there a way to verify  if time machine is backing up my apple mail?  I was told that if I change computers, that the mail files will all be on time machine and can be easily be put on a new computer using my time machine backups.  Is this true? Thanks, Dave

    Having deleted some Mail messages by mistake, I have had to recover them from TM. I can tell you that the recovery of mail messages will be done at the mailbox level. In my case it was half of the messages in a mailbox. So I recovered the complete mailbox from TM. Then I copied the messages from the recovered mailbox back into the mailbox I use in Mail. I hope that helps.
    Please be aware that TM is a backup application and not an archival application. What that means is that if your TM drive gets full, it will get rid of older files which could be mail messages to make space for newer backups. You might want to consider archiving your mail instead of using TM if you need to maintain your mail messages for extended periods of time.
    Allan

  • Where are Thunderbird e-mail files stored on my computer?

    I have read the suggested articles and followed the instructions as best I can, but I still cannot figure out how to get to profile (the path revealed in "Troubleshooting Information," by clicking "show folder," was not what I found on my computer---one element in the supposed path, "AppData," simply was not there in the tree) unless I somehow missed a hidden clue. Furthermore, even if I manage to get to profile, I still don't comprehend how to move my e-mail files from there to a location on my computer that is easy to get to and to back up along with all my other data files.
    Perhaps my level of knowledge is too modest here because the assumption is that I know more than I actually do know. If that is the case, I apologize, but that does not resolve the issue. I wonder why the folders containing e-mails are not placed in an obvious and handy location to begin with, but that of course is a different matter.
    But right now, all I want to do is to (1) get to profile, (2) understand how to back up the actual profile (or profiles, if I ever have more than one, which I don't quite understand, either), and (3) comprehend how to separate out and move the e-mail files/folders located there to an easily accessible and obvious (to me) location. I would greatly appreciate some basic-level instruction on this.
    (I might mention that because it did not meet my needs generally, and also because it was most inconveniently down periodically, otherwise difficult to use far too frequently, and administered with shockingly scant attention to customer satisfaction despite its full-bore commercial nature, I abandoned AT&T/Yahoo web mail for a computer-resident POP client. I chose Thunderbird on the recommendation of a knowledgeable friend. I had used Outlook with relatively good success quite some time ago but have a fundamental aversion to patronizing Microsoft when I do not absolutely have to do so. That is why I am trying with much energy to get Thunderbird to work for me with some reasonable degree of convenience and functionality.)
    Thank you.

    ''re: A folder-copy isn't easy to read,''
    Only if you need to read a specific email as emails are not stored in separate .eml files. They are stored in mbox files which look like a long text document containing emails written one after the other in the order downloaded. But for backing up and reinstalling a Profle which contains all your data, it is stored exactly as required for reinstalling. It also stores all your preferences and account details and so on - eg: address books.
    ''re: if its not compressed it also includes all deleted files.''
    What gnospen actually means is 'compacted' not compressed. They are two entirely different things which should not be confused. You can easily empty the Deleted and Junk folders and then compact all your folders before backing up. This resolves this if it is of a concern to you.
    As gnospen says, ImportExportTools is an excellent tool for backing up emails - not your Profile, not your account settings and preferences and not your address books.
    You can choose to use to store emails as separate .eml files or HTML or plain text format or as a single text file or pdf format or export the entire folder in mbox format with or with subfolders.
    If you want to use ImportExportTools, Thunderbird needs to running, I would advise you go into Offline mode whilst backing up as you do not want your folders synchronising whilst performing this task.
    Here is a link to ImportExporttools addon:
    * https://addons.mozilla.org/en-US/thunderbird/addon/importexporttools/
    I suppose what you need to determine is what do you want to backup.
    I would advise, if you want all your prefernces, account settings, address books and emails saved in one go, then copy the Profile to create a backup or use MozBackup tool.
    If you only want to backup emails then use ImportExportTools addon tool.
    If not backing up your entire profile, but you do want to keep a backup of address books then you can go to Address Book and select the address book, then Tools > Export as either LDIF or comma separated .csv file.
    Note: comma separated .csv files can be opened by other programs such as Excel and can also be easily imported into any email client or back into Thunderbird.

  • I installed the system update to 10.7.3. After re-booting, my mail file was missing from the dock.  Looked in applications and the mail application is missing. Any thoughts?

    I installed the system update to 10.7.3. After re-booting, my mail file was missing from the dock.  Looked in applications and the mail application is missing. Any thoughts?

    Thanks Paul; but, taking your suggestion didn't solve the problem.  As mail is part of the OS, the updates don't have the capacity to reinstall applications; so, I had to reinstall the OS.  I now have my mail back (although it didn't appear on the dock--I had to go to applications and activate it and then put it back in the dock.  Thanks again for trying.

  • How can I transfer Mail files from 10.6.8 to 10.8

    I've used three support calls in an attempt to save my OS10.6.8 Mail files to a new Powerbook Pro. Migration Assistant left me with so many odd artifacts that I earased the whole thing. Then I tried importing files and finally, I tried copying the contents of Library-Mail to the same place in Mountain Lion. All the mailbox labels appeard, but there was no mail in them. I can't see using Time Machine to do this, because it simply can deal with the apparent change in format.
    Does anyone have a way to accomplish the transfer of 10.6.8 mail to Mountain Lion?

    Open the Mac App Store and try purchasing Mountain Lion 10.8. If you get told it's incompatible, choose About this Mac from the Apple menu, check if the computer has at least a Core 2 Duo(not Core Duo) or better CPU with at least 2GB of RAM, and if it does, phone the online Apple Store and order a download code for Lion 10.7.
    (83668)

  • How to restore mail files from Time Capsule onto a different machine?

    My Macbook Pro hard drive crashed, and I want to restore my backed-up mail files from Time Capsule onto my Desktop Mac (iMac 27").  When I try to restore by opening Time Capsule with Mail already open, I can only see the current mail files on the iMac (not the backed up files on the MacBook Pro), even when I point to the MacBook Pro backup file.

    Hello there, AngryMario.
    The following Knowledge Base article offers up how to restore mailboxes and content using Time Machine:
    Mail (Mountain Lion): Restore mailboxes and their content
    http://support.apple.com/kb/PH11713
    Thanks for reaching out to Apple Support Communities.
    Cheers,
    Pedro.

  • Where do i find mail files on hard drive that has been removed? Mac OSX 10.8

    I can not find the files where most posts direct me to look - there is no "LIBRARY/MAIL
    When I go to Library, there is no mail folder....?
    The HDrive used to be an internal drive, and now is connected via USB, as an external drive connected via SATA cable. I want to find some of my old 'sent mail' items and all the mail files in general.
    Files in general are accessible on the drive, but I am not booting off the drive, nor am I able to. thanks - JP

    User/Library/Mail folder.

  • Need help accessing Mail files after Updgrade to OS X 10.5

    I recently did an Erase and Install of my new Leopard OS X. Before doing so, I copied my complete mail file from 10.4 to an external HD.
    After installing 10.5, I tried to import the old files from the HD and I get a message that says my Mail file is not compatible with this version of OS X. This is a REALLY big problem because I have 8 years worth of contacts stored in those mail files
    I don't know what to do. I have since set-up new mail accounts, so I am using my Mail Program without problems. I need to know how to access my old files. I have tried everything I can think of. Any help would be appreciated.

    which Mail file do you mean? the Mail application itself? that was the wrong thing to copy. the application itself contains no user data at all. all your mail data was stored inside your home directory in the folder homedirectory/Library/Mail. if you didn't back up that folder, your Mail data is gone. Your ONLY chance (and it's a small chance) of recovering your Mail data now is to use data rfecovery software like [Data Rescue II|http://www.prosofteng.com/products/data_rescue.php] or [FileSalvage|http://subrosasoft.com/OSXSoftware/index.php?mainpage=product_info&productsid=1] and try to restore that Mail folder. You should do this ASAP to decrease the chance that this data will be overwritten.

  • Mail search doesn't work well after changing mail file to another drive

    Hi, I need some help making the search in mail work for Mountain Lion. After I changed the mail folder to a new drive, SSD, creating an alias, everything works fine for mail except the search. When I search most of the times I get back emails that I received before doing the change.
    I already tried at rebuilding the mailboxes, and also I erased the Envelop index files, and they rebuilt themselves, and still the search is not working properly for the emails I have received since I changed the mail files to the new drive.
    Other than that the mail program is working well and as I work a lot with search I am experiencing a loss of productivity.
    I wouldn't like to revert it to the old drive, as the new drive is SSD and goes much faster for the big size of my mail fines.
    Thank you for your help !
    Javier

    Apple doesn’t routinely monitor the discussions. These are mostly user to user discussions.
    Send Apple feedback. They won't answer, but at least will know there is a problem. If enough people send feedback, it may get the problem solved sooner.
    Feedback
    Or you can use your Apple ID to register with this site and go the Apple BugReporter. Supposedly you will get an answer if you submit feedback.
    Feedback via Apple Developer

  • How to deal with multiple mail files?

    Here's the story; it's sad but true: After a failed iSync spirited away all of my emails, the Apple Care techie I spoke to a month ago wasn't able to fully resolve the problem. So, currently in my Home Library folder I have 2 Mail files: #1 is labeled "Mail" and #2 is "Mail Copy."
    "Mail" has one sub-folder called "Mailboxes" and four other folders for each of my four POP email accounts (there are also a number of other files that I'm ignoring for the moment like--Envelope Index, Signatures.plist, ect.). All mail from the past 4 weeks is in the folder labeled "Mail." But...
    The other folder in my home library--"Mail Copy"--contains 3 POP email accounts and each one has sub-folders that contain mailboxes with my emails that go back many months. I want to keep the email in both folders, "Mail" and "Mail Copy."
    Problem: How to get the older messages out of "Mail Copy" and back into the current "Mail" folder. Clearly, it would be a mistake to simple drag them from one location to the other, since the "Contents" files and ".plist" files wouldn't match.
    I would be extremely grateful for any guidance the Mail authorities who contribute to this forum might be able to give.
    Also, for the life of me, I cannot figure out where the emails actually reside. The "Mail" folder contains a subfolder entitled "Mailboxes" and it contains subfolders for each mailbox like "Action.mbox" and "Hold.mbox." Then, inside each .mbox folder are other files and usually one folder. Most of these files have names like "content_index," "Info.plist," "mbox," and "tableofcontents." And there is a folder labeled "Messages" and it contains numerous ".emix" files and one "tableofcontents file." My confusion begins when I open a particular POP account folder and find .mbox folders also located there and those folders also contain .emix files. I've searched the entire knowledge base, and I find no explanation anywhere of which files/folders are located where and why.
    Many thanks for your time and trouble, Jay

    The easiest way to combine the old folders with the new is to use the "Import" option in Mail's File menu. Consult the Mail Help topic "Importing email into Mail" for comprehensive instructions for doing that. In your case, the "archived" messages will be the ones in "Mail Copy."
    The actual messages are stored in individual *.emlx files, inside each mailbox folder's "Messages" folder. (For instance, you would find a message in a locally stored, root level mailbox "Action" at path ~/Library/Mail/Mailboxes/Action.mbox/Messages/xxx.emlx, where "xxx" is a number.)
    Some of the files you mention are leftovers from Mail 1.x & are not needed with Mail 2.x. They won't do any harm if left in place, but you can remove them if you wish. (I suggest making a backup of the entire ~/Library/Mail/ folder beforehand, in case something you need accidentally gets deleted.)
    These files are not needed by Mail 2.x: "content_index," all "tableofcontents" files, & files named "mbox." All folders with names ending in ".mbox" are needed, since they contain the .emlx files. You may also find folders in ~/Library/Mail/Mailboxes/ with no ".mbox" extension pared with folders of the same name with the ".mbox" extension (like "Hold" & "Hold".mbox") -- do not delete any of these, as they contain "Messages" folders as well.

  • How can I combine the emails of 2 Apple Mail files?

    My wife stopped using a white MacBook 3 months ago, switched to a 17" MacBook, and now needs to switch back. Is it possible to combine the emails and metadata of the Mail files now on these 2 different MacBooks into 1 file without redundancies and with the pertinent metadata?
    For iPhoto and iTunes, FatCat software has utilities which are performing the duties for me as we speak - is there such a utility for Apple Mail?
    TIA, Allan

    30 minutes ago I started this thread and I would like to ditto this question for Apple Address Book (ie I need to merge the Address Books on 2 different MacBooks into 1 address datafile). TIA, Allan

  • Mail file getting large. How to backup and remove?

    My Mail file is 500 MB and I want to move, say, anything older than two years to a different location so I can search it and find attachments. The archive function seems to just create a copy of the mailbox. Is there some way to move messages like this?
    I have deleted the trash, but the size of my mail file and attachments seems to be bogging Mail down and maybe the system a bit.
    Benjamin Barrett
    Seattle, WA

    When I archive my e-mail, it's about 350 MB, and it seems like it's a bit of a burden on Mail.
    It shouldn't be.  Like I said, I'm almost at 350 MB and it's not a problem.  I was able to make a smart mailbox showing everything more than 1 year old, and within seconds had a snappily-scrolling list of nearly 9,000 messages.  Are all these e-mails still in your In box, or some other mailbox you use every day?  Are they still on the server?
    It's possible that I just need a new Mac--this one is about three years old
    You're more accustomed to Windows, I bet.  Three years isn't much in the Mac world.  I've got a nearly 8-year-old Mac that was still in frequent use - and far more functional than any of the 3-year-old Windows machines at my wife's small business - until the hard drive failed a couple days ago.  I'll probably replace the drive and let it chug right along for another few years.  The only Mac I've ever owned, and used, for less than 7 years was the one I dropped on a concrete floor!
    It's clear that Mail won't work for this purpose
    Not at all...  I'm sure there's something you can do to improve performance.  Perhaps there's something wrong with your system or with your Mail data.  It's hard to give more specific advice at this point, but the fact is, Mail does work for this purpose for me.

  • Windows Mail File on Different Drive

    Hello
    Is there a way to have windows 8.1 mail file on a different drive?
    Thanks

    Hi,
    Did you mean Windows 8.1 mail APP in start menu, isn't it? If so, I doubt there is no way to save these mail file on other location.
    Roger Lu
    TechNet Community Support

  • How do I open old mail files held locally within my Thunderbird profile

    I have several old mail files that are in the imap subfolder of my default Thunderbird profile held in Appdata/roaming/thunderbird.
    The mail accounts are no longer active on the net but I now need to see an old email from several years ago and I can't work out how to get it back in to Thunderbird so that I can read it.

    Whoopee it worked - It's mixed all the folders up with my existing folders in TB, but that's being picky - I can sort that out. Chs!

  • Cannot find MAIL files on the HD

    I'd like to back up all my emails. According to 'help', this is to be found on HD = Library. But MAIL files are not there. Tried a search under MAIL and although dozens of files come up, not the ones want. HELP! Where is all the data stored?

    Each users Mail files from Mail.app are stored in the Library folder in their Home directory. Open a window in the Finder and click on the icon on the left that looks like a house. This is your Home directory. Look inside the Library folder located here and you should see a folder named Mail.
    That's the one you want to back up.

  • Can the Mail files be safe on a network drive?

    Can the Mail files be safe on a network drive? That way more than one computer (same user) can access the mail?

    Depends on what you mean by a "network drive".
    I have "external USB drives", I don't have a network drive.   I had no problems putting the .lrcat files on the external USB drives, and it would surprise me a lot
    if there were a problem putting them on network drives.   "In general", drives are drives, who cares.
    On the other hand, why would you want to?  I have all my photos on a USB drive, but I keep my catalogs (4 of them) on c:\ -- for performance reasons -- I see no reason to do otherwise.  They get backed up and the BACKUPS are then copied to 2 of my 3 external USB drives -- I see no REAL reason to put the catalogs externally or on a network drive -- does not buy me anything other than bad performance.

Maybe you are looking for

  • Error in SMTP

    Error in SMTP Cannot process message in SAP System I am setting up SMTP nodes in XI 3.0 when I tried mail Tcode: so01 and check SOST mail not goes through after trace I got this error 22.05.2008    10:40:05    SX_GENERATE_NDR   Cannot process message

  • Purchase order need to add to Standard program

    Hi Folks, i have standard program RFDEPL00, i have to copy this one into Zprogram and need to add the purchase order number and text into the output display(purchase order number will take from VBAK-BSTNK), could any one help me how to bild the logic

  • SWF file not being generated

    I moved an old project (from Intellij, without Flex artifacts) into a new location and recreated a new Flex project with Flex 4.0 integrated product over the old file structure. However, I am now unable to generate the application's swf file or the s

  • HT5071 How to download paid iBook created using iBook Author

    I would like to submit a paid iBook created using iBook Author and make it available to download in India. Apple does not support downloading paid iBooks in India. Is there a solution for this. Also, is there an enterprise deployment of iBooks ie lim

  • SAP Delivered Business Workflows

    Hi, Does anyone know information about <b>SAP delivered</b> business workflows? And possibly SAP delivered workflows that are available in the Business Process Management (BPM) tool or other tools? Thanks! Audrey