Hi,
I start by apologizing if I am asking a question that I should have been
able to find if RTFM but I can not seem to find the answer to my seemingly
simple question. I will also comment that I am not a perl programmer nor a
database/sql expert as I am sure you will gather.
What I do have is a 3rd party reporting script written for me in perl using
a sybase database.
The script currently matches up a few attributes and tables and returns a
full record of stored DSN (delivery status notices). What I would like is
that it returns the collection EXCLUDING a dynamic email address.
So if I hardcode the select file
SELECT data.data_msgid, data_recipient||data_status||data_timestamp
FROM data, doc_message, doc_state, input_state
WHERE data.data_msgid = doc_message.message_id
AND doc_state.input_queue_id = doc_message.input_queue_id
AND doc_state.input_job_id = doc_message.input_job_id
AND doc_state.doc_seq_num = doc_message.doc_seq_num
AND doc_state.proc_seq_num = doc_message.proc_seq_num
AND input_state.input_queue_id = doc_state.input_queue_id
AND input_state.input_job_id = doc_state.input_job_id
AND (doc_state.proc_state = '2' OR doc_state.proc_state = '3')
AND doc_state.input_queue_id = '$queue_id'
AND doc_state.input_job_id = '$job_id'
AND input_state.biller_short_name = '$appid'
AND data_recipient != 'sample\@sample.com.au'
<mailto:'sample\@sample.com.au'>
AND data.data_timestamp <= '$end_time'
ORDER BY data.data_timestamp");
$sth->execute;
This works when you '\' the @ symbol. but I can not find the syntax required
to use a variable $ignore_email.
I have attempted to set $ignore_email = 'sample\@sample.com.au'
<mailto:'sample\@sample.com.au'> and it does not work. I have tried most
combinations of single and double quotes.
This select is located inside a perl library called by a perl script.
I would like to be able to pass the script an email address that I would
like the select to ignore. I am sure it will be a simple syntax issue but I
am stuck
Thanks for your time
Cheers
sach
**********************************************************************
IMPORTANT
The contents of this e-mail and its attachments are confidential and intended
solely for the use of the individual or entity to whom they are
addressed. If you received this e-mail in error, please notify
the HPA Postmaster, [EMAIL PROTECTED], then delete
the e-mail.
This footnote also confirms that this e-mail message has been swept for
the presence of computer viruses by MimeSweeper. Before opening or
using any attachments, check them for viruses and defects.
Our liability is limited to resupplying any affected attachments.
HPA collects personal information to provide and market our services.
For more information about use, disclosure and access see our Privacy
Policy at www.hpa.com.au
**********************************************************************