I am trying to retrieving all email address using particular domain extension for e.g. gmail.com
I wrote the below query
Select policyid,emailaddress from policyholder WHERE policyholder.EmailAddress like '%gmail.com%'
It works fine, but i want to use the LIKE condition against ‘emailaddress’ column in email table as I have more than 100 domain extensions
I wrote something like
WHERE policyholder.EmailAddress like (select emailaddress from email) but I am getting the below error
Msg 512, Level 16, State 1, Line 1
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
Hi,I wanted to get the domain name from the email in a query..So if the email is Join Bytes!, I just to display hotmail.comThanks in advance for the help.AJ
We have an identifier of who has performed an ection which populates a table with their email address in the format firstname.surname@domain. I am looknig for some code to split out the first name and surname (and, if possible, capitalise both) so uor audit report can show the actual name instead of the email address.
Has anyone encountered this issue previously and know a solution?
Is there a handy-dandy way for me to be able, from a stored procedure, to capture the notification email address for a user associated with a job?
I need to send an email out from a stored procedure, and I want it to be set up to send to the same user that is set up in the job that calls the stored procedure.
the same notification stored proc will be used in multiple jobs, but the jobs are already set up with a notification email to be sent to the defined users "on completion" (error or not). I want a separate email to be sent, but I want to use xp_Sendmail because I have to perform a select who's output I want to appear in the body of the email (and unless I am missing something, I have no control over the body of the standard "job completion" email).
I would prefer to NOT have to "hard code" the user email address in the stored proc that calls xp_sendmail, OR to put it in some user table in the database, when the user I want to send it to will always be the same one defined in at the JOB level in Enterprise Manager.
Any thoughts? Thanks in advance for your instantaneous and informative answer-packed responses! ;)
I'm trying to strip out the First & Last Name from an Email Address. The email address is formatted as "FirstName.LastName@emailaddress.com" but sometimes a middle initial is used (ex: "First.M.Last@emailaddress.com").
I can locate the '@' sign and the first '.' period(from left to right) but need to find the first '.' from the left of the '@' sign.
I'm doing this in a view.
Here's some sample data and what I've tried:
CREATE TABLE dbo.Table1 (EmailAddr VARCHAR(255)) INSERT INTO dbo.Table1 (EmailAddr) SELECT 'Andy.Smith@gmaddr.com' UNION ALL SELECT 'Betty.Lee-Jones@gmaddr.com'
Hello, I will like to know the best practice for grouping email addresses in a table.
We have a basic table that has email address for admin users. Which goes thus
CLIENTS EMAIL
emailID int username: varchar 20 Client_email varchar 150
The Above table is for our admin users. Enabling them to send out emails to clients. Based on their bills.
We have a second table for mass mailing. Which has emails in groups. Each group is based on the above entry. And groups could range from 5 users up to 100,000 users.
Whats the best way to implement this.
Do I create a seperate column for each email entry, knowing that this table would be extremely big, with a lot of repeated values, ie username etc. Or group them TOGETHER as varchar(max)
Hi,I have 2 fields in a database: 'email' and 'website'.In the majority of cases, the website field is not populated even though theemail address is. In 90% of cases, the website will be 'www.' followed bywhatever is after the '@' symbol in the email address.Would anyone be able to help me with the SQL that would take whatever isafter the '@' sign in the email address, add it to 'www.' and populate the'website' field?Thanks!
i ve a filed named "Email" of datatype .i ve created this field to insert email address in this field.but when i insert an email address like "bilal@yahoo.com" from a textbox wh is in an ASP.net webpage then in the filed i see this "System.Web.UI.WebControls.TextBox". can u plz tell me how to fix this Regards Ahmed Bilal Jan
(NOTE: FROM a NON-IT PERSON) We've implented SQL 2005 and Reporting Services, but our subscriptions only work internally: when we try to send reports via subscriptions to valid external email addresses, we get a message: invalid email address and the entire subscription does not work.. PLEASE ADVISE. IT WILL BE GREATLY APPRECIATED!
I would like to use ISS to extract the user name and email address out of the active directory. I would like to put it in an MS-SQL 2005 table that I can use stored procedures on. I am hoping I can use a query to do it but I understand there is a 1000 entry limit on the extraction of the Active Directory and I have more than 1000. Could someone point me in the right direction please. Thanks.
I just moved our SSRS server from one machine to another. It was sending our report emails from a service account. So when my end users get the emailed report it was from a service account (reports@blah.com) .
Now that I moved the DB to another server - the reports get emailed successfully - but they are being sent from my email address!
I have checked the rsreportserver config file. I also checked in the report server smtp setup and they both show the service account. I even checked the subscription owners and accounts.
SSRS is using my account, but I can't find where it's getting it from. Where else can I look?
how do I set up a SQL2000 server to send an alert to both an email address and a pager when a specific event occurs..please help!!! The server is in a different location and we need notification of problems!! thanks
Dear Mr Portas and Mr Sommarskog,Cause I am a newbie in sql, can I ask for your email address?My email Address is Join Bytes!ThanxBest RegardsMichael--Message posted via http://www.sqlmonster.com
We are using SQL Server 2012 . We have configured the Database mail Services. Issue is, the mails are going to only inside the domain not going cross domain Email address like hotmail,gmail and etc. But from outlook client the mails are going to cross domain Emails. Same issue is in SSRS Email Services also. We have checked the SMTP Server, we could not figured it out.
The Browser role has the task Manage Individual Subscriptions. Fine, the user can create a subscription. The problem is that the reportserver populate the email address text box with the Windows User ID and does not let the user change this to put his email address instead. The text box is greyed out.
I found that to enable the text box I have to add the task Manage all subscriptions to the role "Browser".
This is a major security problem because with this setting any user can edit any subscription.
I suspect that I could work at the Active Directory level to populate a field that would in turn populate the email address with the correct data., however this is not an option for me. I have absolutely no way to do it or get it done. Does anybody has an idea on how I could allow a user to edit his email address in his subscriptions and not let him tamper with other users subscriptions?
I have successfully set up a Report Subscription and it sends the report to our internal users at a given time each day.
I recently added an external email address in the 'CC' & 'BCC' boxes but i got an error saying the address was invalid (i've tried with just the 'To' box as well). There's nothing special about the external address, i've tried with gmail, BT, and Yahoo.
So it would seem that any address outside of my local domain is invalid.
Is there some config setting that i'm overlooking? Has anyone had this problem?
I am implementing a fax solution (Right Fax) and pulling email information from a table and passing into a variable. In order to send out a fax via email, the syntax is in the following example below:
Example:
To send a fax from Outlook to Jane Doe at 555-1212, enter:
[RFAX:Jane Doe@/FN=555-1212]
When the following syntax gets passed into the Send Mail Task, into the "To" line and the package is executed I'm receiving the following.
[Send Mail Task] Error: An error occurred with the following error message: "The specified string is not in the form required for an e-mail address.".
[Send Mail Task] Warning: The address in the "To" line is malformed. It is either missing the "@" symbol or is not valid.
I realize it’s a malformed email address. Is it possible to create a group and instead of the fax syntax pass the group name?
I have subscription by email problem on the following configuration:
Windows XP prof. SQL Server 2005 Enterprise Configured Database Mail with remote SMTP server to send email successfully Configured SSRS to use remote SMTP server
Edited the Rsreportserver.config file as following (by the instructions from MSDN)
I scheduled my subscription and tested it. I didn't receive any mail from the setting email address, but got an error message in ReportServerService log file as following.
Error sending mail, CDO error -2147220978, will not resend Error sending email. System.Runtime.InteropServices.COMException (0x8004020E): The server rejected the sender address. The server response was: 530 authentication required - for help go to http://help.yahoo.com/help/us/mail/pop/pop-11.html
I did a little search, but couldn't find any solution for it. Is anybody successfully to get the Reporting Services subscription by email function working through MS SQL Server Management Studio or if you have a solution for this issue, would you mind to share the experience with me. I will be very appreciated.
Hi everybody. I am new to VBA,.,, I Have created a folder under inbox in Outlook 2007 which stored the receipients information like name, E-mail, which is not present in the address book of outlook. I have imported this folder in access 2007. My problem is ... it does not display the email address. Rest of the informations is displayed... Is there any way i could do this.?? is there any way i could get the email addresses to appear(import/get) in to the access table??? Is there any module i mite have to create??
I doubt this is possible, but can someone think of a way to change the email address used for sending report subscriptions based on the report or subscription?
It's a need that I've heard from a number of different clients. Scenario: a company has one reporting services server with reports running from numerous departments. Report subscriptions are sent to internal and external email addresses and there's a business need to use different "from" addresses based on the report (or audience).
Hi,I have an Address table which contains more than one addresses for aparticular member. I want to write a query that would only displaymost current address. All addresses have a unique ID (addID).Example:memberID addID address1-------- ------ --------------------------------------------------295 69 13 Auster St295 70 465 Lorre Ct295 71 P.O. Box 321722 171 10 Hannaford Rd722 172 Dubai, United Arab Emirates
-A "master domain" AD, a "sub domain" AD, a trust relationship between the two (sub trust master) -A sql server 2005 on a win server 2003 in "sub domain" AD -A linked server to "sub domain" AD -A linked server login using a "sub domain" admin acccount -A view to this linked server -A grant on masterDomain/Domain Users to the database -A grant on subDomain/Domain Users to the database -We want all connections done through "Windows Authentication" not "Database Authentication".
Queries on the view work fine using "sub domain" user accounts. Queries on the view fail using "master domain" user accounts (including master domain admin accounts)
"Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "ADsDSOObject" for linked server "ADSI" reported an error. The provider indicates that the user did not have the permission to perform the operation."
All connections are done through "Windows Authentication" not "Database Authentication".
Can we establish cross domain connectivity with "Windows Authentication" ?
Below are details of the implementation:
SELECT TOP (100) PERCENT * FROM OPENQUERY(ADSI, 'SELECT displayname, givenName, sn, cn (etc...) FROM ''LDAP://OU=PEOPLE,DC=subDomain,DC=com'' WHERE objectCategory = ''Person'' AND objectClass = ''user'' ')
In SQL Server Mngt Studio in Server Objects/Linked Servers/Providers/ ADSI properties security tab I have:
"connections will: <be made using this security context> Remote login:'subDomainAdminAccnt' With password: 'subDomainAdminAccntPassword'
Error: Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "ADsDSOObject" for linked server "ADSI" reported an error. The provider indicates that the user did not have the permission to perform the operation.
Msg 7320, Level 16, State 2, Line 1
Cannot execute the query "SELECT displayname, givenName, sn, cn
FROM 'LDAP://OU=PEOPLE,DC=subDomain,DC=com'
WHERE
objectCategory = 'Person'
AND objectClass = 'user'
" against OLE DB provider "ADsDSOObject" for linked server "ADSI".
After using ADMT to migrate the domain user or group into the root domain, when I use enterprise manager to try and change the permissions allocated to that domain user/group, i get the 'Error 15401 NT user or Group not found'.
This is a correct error as the user is now in the root domain, however sql (in sysxlogins) still thinks its in the child domain.
Is there a simpler way, other than collecting the users permissions, deleting the user from SQL then adding back in with the correct domainusername format, then adding the permissions back?
I tried renaming the 'name' in sysxlogins (not recommended) and while that worked, whenever I tried to add the migrated user to another database, the login name was missing and would not resolve.
I believe it is something to do with the SID not matching.
we recently migrated from our in-house domain to the Enterprise domain. Everything went smooth except for the fact that I can no longer accept my dBs using my SA or my domain admin account. There is only 1 account I can get into the management studio with but it has no admin privileges, so I can't make any password changes or add accounts. I don't have a test environment so kind of hesitant to experiment with our production system.
In my procedure I need to pull data from a database which is on other server and domain.
As usual I have used the below query but having troubles with mode of authentication.
SELECT * FROM OPENROWSET('SQLNCLI', 'Server=x.x.x.xsyz;Trusted_Connection=yes;','SELECT top 10 * FROM pcm.stats.visits') AS a
I get the below error:
"Login failed. The login is from an untrusted domain and cannot be used with Windows authentication"
I understand from the error that the domain and mode of authentication is different.
I use windows auth and we are given sql auth on the remote server which is on different domain.
I was suggested to use 'sp_addlinkserver' to link the remote server and query the data.
I am just curious to know if we can succeed through link server, is there any script to use sql authentication of remote server in my procedure and pull the data.