Adding An Authenticated User From External App

Apr 23, 2007

I have an ASP.NET 2 external application that is using and mix of the web services and tables/sps available from my 2005 SSRS.

I want to add an authenticated user from the external application. I don't see a web service that will do this. I have been through the SP's and can create roles, authenticated users, policies etc. But I think I need to update the XmlDescription field in the SecData table.



Do I need to build this XML string from scratch or is there a function / sp / web service that will do this. XML is a long ways from my strong suit.



Or am I just crazy and I should redirect my users to the Security tab!



Any help or advise would be appreciated.

View 6 Replies


ADVERTISEMENT

Cannot Logon With Authenticated User When User Database Is Removed

Dec 12, 2007



Hello,

We have a new production server with SQLserver 2005.
Our department responsible ofr the installation made it as secure as possible, however.
I have to put a new backup on to the server from the old production server.
We ran into a problem when we removed the old database.
I could not longer logon to the server with an authenticated user.

"A connection was successfully established with the server, but an error occured during the login process"
"Shared memory provider : error 0 : No process is on the other end of the pipe"

Strange thing is when i create a new database with the same name. The user can logon to the server again.

Any idea's ?


Jurgen

View 1 Replies View Related

User Authenticated

Sep 15, 2005

Hello,
In SQL, suser_sname() gives me connection user name (I am using a single user to create all connections), I authenticate users through a login form aginst a SQL login table. Is there any way I can get a username authenticated in an SQL query?
 
Thanks,

View 1 Replies View Related

Connection String With Authenticated User Info

Jul 6, 2006

Hi.  New to ASP.NET and first time posting.
My web app connects to a SQL database - SQL authentication. 
Users login to the web app through the login server control.  Once authenticated, it is my understanding that the user name and password are stored on the client as a cookie. 
How do you programmatically get this user info and use it for the userid and password parameters of the connection string?
Is there a better way to use the authenticated user info to access a SQL database?
Thanks

View 2 Replies View Related

Query To Add Windows Authenticated User Via Remote

Jun 17, 2007

I was able to do this on a Windows XP machine but I am not able to get this to work on a Windows 2003 Server machine.
I am connecting to the Windows 2003 Server and MS SQL Express via remote desktop on the lan.

This is what worked for me before:
EXEC sp_grantlogin '4800X2ASPNET'
USE MyDB
EXEC sp_grantdbaccess '4800X2ASPNET'
EXEC sp_addrolemember 'db_owner', '4800X2ASPNET'

But for some reason now I am getting this error:
Msg 15401, Level 11, State 1, Procedure sp_grantlogin, Line 49
Windows NT user or group '4800X2ASPNET' not found. Check the name again.
Msg 15401, Level 16, State 1, Line 1
Windows NT user or group '4800X2ASPNET' not found. Check the name again.
Msg 15410, Level 11, State 1, Procedure sp_addrolemember, Line 75
User or role '4800X2ASPNET' does not exist in this database.

I thought what I needed to add was the name of this pc that will connect remotely, but that doesn't seem to be working.
What weird is the old copy of this query I used had the local pc as the computer name. If I exchange the computer name from the remote pc name to the local 2003 Server machine name, the query works fine. Although that still doesn't let me add connections via Web Developer Express without error. It doesn't make sense to me anyhows, how could I have used the local machine's name and not the remote machine's name to get this to work previously. So confused.

Thank you in advance for help.

View 1 Replies View Related

Query To Add Windows Authenticated User Via Remote Desktop [MS SQL Express]

Jun 17, 2007

I was able to do this on a Windows XP machine but I am not able to get this to work on a Windows 2003 Server machine.I am connecting to the Windows 2003 Server and MS SQL Express via remote desktop on the lan.This is what worked for me before:EXEC sp_grantlogin '4800X2ASPNET'USE MyDBEXEC sp_grantdbaccess '4800X2ASPNET'EXEC sp_addrolemember 'db_owner', '4800X2ASPNET'But for some reason now I am getting this error:Msg 15401, Level 11, State 1, Procedure sp_grantlogin, Line 49Windows NT user or group '4800X2ASPNET' not found. Check the name again.Msg 15401, Level 16, State 1, Line 1Windows NT user or group '4800X2ASPNET' not found. Check the name again.Msg 15410, Level 11, State 1, Procedure sp_addrolemember, Line 75User or role '4800X2ASPNET' does not exist in this database.I thought what I needed to add was the name of this pc that will connect remotely, but that doesn't seem to be working.What
weird is the old copy of this query I used had the local pc as the
computer name. If I exchange the computer name from the remote pc name
to the local 2003 Server machine name, the query works fine. Although
that still doesn't let me add connections via Web Developer Express
without error. It doesn't make sense to me anyhows, how could I have
used the local machine's name and not the remote machine's name to get
this to work previously. So confused.Thank you in advance for help.

View 1 Replies View Related

Query To Add Windows Authenticated User Via Remote Desktop [MS SQL Express]

Jun 17, 2007

I was able to do this on a Windows XP machine but I am not able to get this to work on a Windows 2003 Server machine.
I am connecting to the Windows 2003 Server and MS SQL Express via remote desktop on the lan.

This is what worked for me before:
EXEC sp_grantlogin '4800X2ASPNET'
USE MyDB
EXEC sp_grantdbaccess '4800X2ASPNET'
EXEC sp_addrolemember 'db_owner', '4800X2ASPNET'

But for some reason now I am getting this error:
Msg 15401, Level 11, State 1, Procedure sp_grantlogin, Line 49
Windows NT user or group '4800X2ASPNET' not found. Check the name again.
Msg 15401, Level 16, State 1, Line 1
Windows NT user or group '4800X2ASPNET' not found. Check the name again.
Msg 15410, Level 11, State 1, Procedure sp_addrolemember, Line 75
User or role '4800X2ASPNET' does not exist in this database.

I thought what I needed to add was the name of this pc that will connect remotely, but that doesn't seem to be working.
What weird is the old copy of this query I used had the local pc as the computer name. If I exchange the computer name from the remote pc name to the local 2003 Server machine name, the query works fine. Although that still doesn't let me add connections via Web Developer Express without error. It doesn't make sense to me anyhows, how could I have used the local machine's name and not the remote machine's name to get this to work previously. So confused.

Thank you in advance for help.

View 1 Replies View Related

SQL 2012 :: Allow Authenticated User To Query Excel File Via Linked Server?

May 25, 2014

I have a 3rd party dashboard application that I can only use SQL authenticated logins to connect to the database.

I'm trying to create a query within the application that will directly access an excel file through a linked server.

As a test, I login to SSMS as the sql auth user to run the linked server query below but the following error is returned:

select *
from Corporate...[Sheet1$]OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "Corporate" returned message "Cannot start your application. The workgroup information file is missing or opened exclusively by another user.".
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "Corporate" reported an error. Authentication failed.
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "Corporate".

When I login as a Windows auth user, I can successfully run the above query.

I noticed within the linked server's security definition that I cannot specify a windows auth user as the mapped Remote User or as the Remote login

I've tried creating a Credential object with the identity of the windows user and assign that object to the sql auth user but to no avail. I still get the same error

I am using SQL Server express so the option of an automated server agent job to import the excel file is not available.

Details:
SQL Server Express 2012
Office version: Excel 10
Provider: Microsoft.ACE.OLEDB.12.0

View 9 Replies View Related

Login Failed For User On External Webhosting

Nov 20, 2005

I get the following error message when trying to access SQL server database hosted by Godaddy.com.  I've enabled ASP.net 2.0 and setup SQL 2005 schema, followed their directions for the connectionstring and am using the SQL account and password I setup on Godaddy's website to access the SQL database.  When I attempt to use the built in create user or login form  that I created from visual studio express that works while using sql 2005 express on my localmachine, it gives the following error message:
Login failed for user 'ysatrifecta'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Data.SqlClient.SqlException: Login failed for user 'ysatrifecta'.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. 
Stack Trace:
[SqlException (0x80131904): Login failed for user 'ysatrifecta'.]   System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +734931   System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +188   System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1838   System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK) +33   System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +628   System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +170   System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +359   System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28   System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) +424   System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) +66   System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) +496   System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +82   System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +105   System.Data.SqlClient.SqlConnection.Open() +111   System.Web.DataAccess.SqlConnectionHolder.Open(HttpContext context, Boolean revertImpersonate) +84   System.Web.DataAccess.SqlConnectionHelper.GetConnection(String connectionString, Boolean revertImpersonation) +197   System.Web.Security.SqlMembershipProvider.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) +3612   System.Web.UI.WebControls.CreateUserWizard.AttemptCreateUser() +305   System.Web.UI.WebControls.CreateUserWizard.OnNextButtonClick(WizardNavigationEventArgs e) +105   System.Web.UI.WebControls.Wizard.OnBubbleEvent(Object source, EventArgs e) +453   System.Web.UI.WebControls.CreateUserWizard.OnBubbleEvent(Object source, EventArgs e) +149   System.Web.UI.WebControls.WizardChildTable.OnBubbleEvent(Object source, EventArgs args) +17   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35   System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +115   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +163   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102
 
Can anyone help?

View 1 Replies View Related

Unable To Send Database Mail To External User

Jul 13, 2015

I have two domains. forest domain abc which has the exchange infrastructure. forest domain xyz which does not have exchange. There is a two way trust set up.

I have set up database mail which sends internally but not externally on the xyz domain its uses mailrelay address to comunicate with exchange. The receive connector is set up correctly on exchange on domain abc as I have managed to send email from a sql server to external contact in the abc domain.

The IP addresses are correct on the receive connector.

The problem is I am unable to send to an external contact from the sql server in the xyz domain. Not sure if this an exchange issue or database mail.

View 2 Replies View Related

Programmatically Adding A User To The System User Role

Dec 27, 2006

We have been working on an application that will be using a forms-authenticated report server (RS2005) as a reporting back-end. Using the reporting services web service I have been able to assign permissions to objects in reporting services no problem. The issue is that each user needs to be added to the System User role to be able to use the report builder properly. I can't seem to find a way to do this programmatically. Any idea?

View 1 Replies View Related

Adding A User/role To All User Database

Jan 23, 2001

Hi everyone,

I try to add a db_role or a user to all my databases with one script. Although parsing doesn't report any problem I get a Syntax error during execution.
I first select the database names into a #temp table which has two columns, ID and dbname.
After that I use the following code:

DECLARE @Count smallint
declare @dbVarchar(20)

SET @Count = 1

WHILE (@Count <=(SELECT MAX(ID) FROM #temp))

BEGIN

Exec ("USE @db")

EXEC sp_adduser 'test'
EXEC sp_addrolemember 'my_role', 'testrole'


SET @COUNT = @COUNT + 1
SET @db = (SELECT dbname FROM #temp WHERE ID = @Count)
END

It seems that the "Use @db" part has no value for the variable @db.
Does anybody knows how to solve this?

View 1 Replies View Related

Adding A User...&#34;user Already Exists&#34;?

Sep 6, 2000

SQL7 -

Had a user created from a local NT account called joe. Used mixed mode athentication. Things are fine.

Later, we needed to add all users from primary domain account (domain2joe), and not have users on all the local servers (joe). Instead central athentication. So I removed the SQL user bill(that was there from local NT account), then went ahead and added the same username, but from a different domain (domain2joe). (same SQL username!) Now when I go into database access to grant user joe access to database1, SQL complains saying that the user already exists. I check the database1 and the user isn't there. BUT, the user bill exists on the SQL role "public" of that database.

I can I add this user and grant access to database1 when SQL thinks the user already exists?
How do I remove user from public role?

thanks in advance,

View 1 Replies View Related

Adding NT User Id To SQL 6.5

Aug 12, 1999

Does anyone know how to programmatically do the functions that SQL Security manager is doing when it moves an NT login into SQL?

I want to automate the task of granting NT users the ability to do a trusted SQL connection.

thanks Jeff

View 1 Replies View Related

Adding A New User

Mar 28, 2006

hey guys,

i'm trying to add a new user to a certain database directly through the users section in this database, but i was given an error that i can't and nothin was added, so i tried adding this user from the Logins section, a pop up message showed saying that this user already exists knowing that it doesn't when i try to create a user from the Logins in a different username it worked but the problem is i can't change the user i must stick with the username that is not working.
how can i fix it??

Thanks,
Oliver

View 1 Replies View Related

Adding New User To SQL Server

Mar 16, 2008

Hi, I'm able to connect to my db using ASP.NET, but now I need to connect with ASP. I need to add a user like <computer name>ASP( I already have <computer name>ASPNET) using windows authentication to the db. I cannot seem find the way to do this in SQL Server management Studio, because it tells me that it doesn't find that group. Where can I add this user?Thanks a lot. 

View 3 Replies View Related

Adding A User In Every Database

Oct 29, 2001

I am trying to add a user in every database. So far I have tried using a cursor - Wont work because you cannot issue Use @database_name within the cursor. I have also tried master.dbo.sp_MsForeachdb "exec sp_grantdbaccess 'user'" this does not work either as it addes the user to the first database then doesnt cycle through. I also tried fully qualifying the sp_grantdbaccess with master.dbo.sp_grantdbaccess.

If you have a way of doing this i would appreciate some help.

Thanks

Bill

View 4 Replies View Related

Droping And Adding New User

Aug 23, 2005

Hi All,I am having a serious problem of removing and adding again an user in adatabase.Microsoft SQL Server 2000 - 8.00.760 (Intel X86)Dec 17 2002 14:22:05Copyright (c) 1988-2003 Microsoft CorporationEnterprise Edition on Windows NT 5.2 (Build 3790: Service PackSomehow, the user was created earlier but was not able to run queryassigned to him. As a result I wanted to drop and recreate the user.I have done many possible things to create the users again with thesame user id but failed.1. I tried to delete this user from the enterprsie manager security-->logins-->user1It deletes but when I try to add again, it gives me error message(Error 15023: user or role u'user1' already exist).2. Then I tried in the db:delete sysusers where name='user1'it deletes the user1.3. Again tried adding, got the message in 1.4. Then I trieduse db1EXEC sp_change_users_login 'Update_One', 'user1', 'user1'Server: Msg 15291, Level 16, State 1, Procedure sp_change_users_login,Line 88Terminating this procedure. The User name 'user1' is absent or invalid.I also tried master database and ran the following.EXEC sp_droplogin 'user1'The login 'user1' does not exist.But If I try to add the login user1, get the error message.Error 15023: user or role u'user1' already existI also ran the following when I got Ad hoc error messageexecute sp_configure "allow updates",1goreconfigure with overridegoCould you please tell me how I can solve this problem.I do highly appreciate your help.Thanks a million in advance.best regards,mamun

View 1 Replies View Related

Adding A New User Login

Jul 20, 2005

In Ms SQL 2000, I want to be able to share my database with another user butI only want them to be able to look at the database and not be able tochange anything.Does anyone know how I go about doing this?

View 1 Replies View Related

Error 21770 Adding New User

Aug 17, 1999

Dear All,

I have inserted a new NT user via the Security Manager applet into a group associated with two databases. Now when I select 'Logins' from the Server Manager window and then double-click the newly added user, I receive this message 'Error 21770: The name '<NT username>' was not found in the Users collection.'

Can anyone please explain the above error message.

Thanks

View 1 Replies View Related

Adding A User To A Read-Only Database

Aug 1, 2007

Hey guys,

I currently have a sql server 2000 sp4 instance with a read-only db on it. We get tlogs shipped from an outside vendor and keep a copy of the production database in house for reporting purposes. The database is in read-only mode because we apply new tlogs daily. Recently we did a full recover and applied 2 tlogs.

The issue:
There is a user YYY in the database and at the server level, but they aren't linked. So I do what I usually do and run the following command:

exec sp_change_users_login 'Update_One', 'YYY','YYY'

Except for I get the following error:

Server: Msg 3906, Level 16, State 1, Procedure sp_change_users_login, Line 109
Could not run BEGIN TRANSACTION in database 'ZZZ' because the database is read-only.

Now this error makes sense and I understand why, so my question is how do I fix the users not being linked?

View 1 Replies View Related

Adding User Define Fields Together

Apr 5, 2004

This is driving me crazy! The SQL Statement refenced is shown at the end of this email.

When I try and run the statement, an error is raised saying that Undrawn_GT5MIL_LE365Days is invalid (likewise for Undrawn_LE5MIL_LE365Days). From what I can gather, it is saying that I cannot include a User Defined variable in another argument. This is unlike Access. Any suggestions?


SQL View.......

SELECT TOP 100 PERCENT QRY_FacNew_Term.Category, QRY_FacNew_Term.Fac_No, QRY_FacNew_Term.Client_Number, QRY_FacNew_Term.Client_Name,

Undrawn_GT5MIL_LE365Days = CASE WHEN Undrawn_CDN >= 5000000 AND Term <= 365 THEN Undrawn_CDN ELSE 0 END,

Undrawn_GT5MIL_GT365Days = CASE WHEN (Undrawn_CDN >= 5000000 AND Term > 365) OR

(Cr_Limit_CDN IN (0, 1)) THEN Undrawn_CDN ELSE 0 END, [Undrawn_GT5MIL_LE365Days]+[Undrawn_GT5MIL_GT365Days] AS Total

FROM dbo.QRY_FacNew_Term

WHERE (Exclude <> 'Y')

ORDER BY Category, Client_Name

View 1 Replies View Related

Error 15401 - Adding AD User To SQL Server

Mar 11, 2008

All,

The current setup is as follows:
SQL 2005 64bit v9.0.3054
Windows 2003 SP2

Problem: When trying to add an AD user to SQL, I receive error 15401

Background: The user's last name was recently changed and so all relevant AD fields were appropriately changed:
Lastname, Displayname, E-mail, UserLogonname, UserLogonname (pre-Windows 2000). The user's previous email account has not been changed except for additional email addresses to account for the new name and old name. Also note, the uses Exchange alias is still the previous account name.

When I enter the user's new account name into the Login Name field in SQL I recieve the 15401 error. When I do a search for the user's new account name SQL finds the previous account name and not the new one. I have reviewed KN 324321 and that article does not resolve this error. The user account can be found be only using the original account name and not the new one.

On the same SQL server, I opened the security settings for a folder and added the new user's account name and it was found. I then had it search for the user's old login name and it could not find it.

Any help would be appreciated...

Regards,

Ian

View 8 Replies View Related

How To Avoid The Need Of Adding User In Administrator Group.

Oct 5, 2006

Hi,

I've created an rdl report in reporting services 2005. Report is working fine. I've deployed this report on SQL Server 2005. The problem is this that to access the reports from client, I need to add client's login ID in Administrator user's group os server. If I dont add them in that group, it shows following error:

"The permissions granted to user 'loginname' are insufficient for performing this operation. (rsAccessDenied)".

This solution works fine in development but in actual environment, I can't add users in that group. Can anyone tell me how to view reports without adding user in administrator group. Its urgent.

Looking forward for help.

View 3 Replies View Related

DB-lib Connect To NT Authenticated SQL Server 7

Feb 9, 2000

Hi,

I have a program using VB and db-lib to connect to the SQL Server 7.0, it was working fine with
SQL Authentication, now when I changed to NT Authentication on the server, it always gave me
login failed(permission denied) error. Since it's a huge program, and I don't have enough
time to rewrite this in ADO, can anyone help? It did connect correctly through query window.

Thanks.

Heidi Zhang

View 2 Replies View Related

Adding Extra Steps To A Create User Wizard Asp.net (c#)

Feb 25, 2008

 Hi, Apologies in advance if you get confused by reading this.... I am trying to create an additional step in the Create Wizard User Control that is provided by ASP.net. The additional step that I want to add will come after a user will create their username, password, email etc. The information which I want to save in the extra step are details such as firstname, lastname, address, height, weight etc. (I am creating an online weight management system for dieticians).When I  run through the application, the username, password etc save perfectly to the database, but nothing happens with the other "personal information". There are no errors thrown so I don't know where the problem is coming from.I have included the code below as I have it:The code behind the Register.aspx file is as follows: <asp:SqlDataSource ID="InsertExtraInfo" runat="server" ConnectionString="<%$ ConnectionStrings:ASPNETDBConnectionString1 %>" InsertCommand="INSERT INTO [aspnet_UserInformation] ([first_name], [surname], [address1], [address2], [city], [country], [number], [height], [weight]) VALUES (@txtFirstName, @txtSurname, @txtAddress1, @txtAddress2, @txtCity, @txtCountry, @txtNumber, @txtHeight, @txtWeight)" ProviderName="<%$ ConnectionStrings:ASPNETDBConnectionString1.ProviderName %>"> <InsertParameters> <asp:ControlParameter Name="txtFirstName" Type="String" ControlID="txtFirstName" PropertyName="Text" /> <asp:ControlParameter Name="txtSurname" Type="String" ControlID="txtSurname" PropertyName="Text" /> <asp:ControlParameter Name="txtAddress1" Type="String" ControlID="txtAddress1" PropertyName="Text" /> <asp:ControlParameter Name="txtAddress2" Type="String" ControlID="txtAddress2" PropertyName="Text" /> <asp:ControlParameter Name="txtCity" Type="String" ControlID="txtCity" PropertyName="Text" /> <asp:ControlParameter Name="txtCountry" Type="String" ControlID="txtCountry" PropertyName="Text" /> <asp:ControlParameter Name="txtNumber" Type="String" ControlID="txtNumber" PropertyName="Text" /> <asp:ControlParameter Name="txtHeight" Type="String" ControlID="txtHeight" PropertyName="Text" /> <asp:ControlParameter Name="txtWeight" Type="String" ControlID="txtWeight" PropertyName="Text" /> </InsertParameters> </asp:SqlDataSource>
 Then the code I have behind the Register.aspx.cs page is: protected void CreateUserWizard1_CreatedUser(object sender, EventArgs e)    {        TextBox UserName = (TextBox)CreateUserWizard1.FindControl("UserName");        SqlDataSource DataSource = (SqlDataSource)CreateUserWizard1.FindControl("InsertExtraInfo");                MembershipUser User = Membership.GetUser(UserName.Text);        //object UserGUID = User.ProviderUserKey;        DataSource.InsertParameters.Add("UserId", UserGUID.ToString());        DataSource.Insert();    } I know there is a problem with the code on the aspx.cs page but I cant figure it out. I need the username / password information to relate to the personal details information. I know I have to create a foreign key in the asp_UserInformation table that will link to the username in the asp_Membership (where all the username / password info is stored) Any help will do, I'm almost in tears here!!!The Spud 

View 1 Replies View Related

Adding A User Defined Date Range To My Reports?

Oct 6, 2005

This is a pretty simple query that tracks 'yesterdays' apply clicks on our website.



SELECT MIN(A.hitDate) AS minDate, D.AffiliateName, B.ProdType, COUNT(DISTINCT A.ipAddress) AS TOTAL
FROM ArchiveApplyTracking A LEFT OUTER JOIN
Configuration.dbo.Affiliates D ON A.affiliateID = D.AffiliateID LEFT OUTER JOIN
Incoming C ON A.campaignID = C.ID LEFT OUTER JOIN
Configuration.dbo.ProductType B ON A.productTypeID = B.ProdNo
WHERE (A.hitDate >= DATEADD(d, DATEDIFF(d, 0, GETDATE() - 1), 0)) AND (A.hitDate < DATEADD(d, DATEDIFF(d, 0, GETDATE()), 0)) AND (A.deal = 1) AND
(A.ipAddress NOT IN
(SELECT ipAddress
FROM [Tracking].[dbo].ipTracking)) AND (B.ProdType NOT LIKE 'refused%') AND (D.AffiliateName LIKE 'ARROW%') AND
(B.ProdType NOT LIKE '%prequalify%')
GROUP BY D.AffiliateName, B.ProdType
ORDER BY D.AffiliateName


No problem there, that's fine.

But how can i put a simple date range interface on my published report so users can say "get me the stats from 04/09/2005 to 20/09/2005, which then runs the query?


Thanks for any help

View 1 Replies View Related

Proper Syntax For Adding Object Name Owned By Domain User

Aug 11, 2005

I am receiving an error based on my query that is giving me the following error:


Code:


[Microsoft][ODBC SQL Server Driver][SQL Server]Invalid object name 'Config'.



I'm assuming that this is because the table was not made by dbo, but my domain account.

The query is currently defined as:


Code:


SQL = "SELECT * FROM Config"



but I'm assuming it needs to be defined with the syntax of ownername.objectname. My problem is when I change the string to this:


Code:


SQL = "SELECT * FROM sanm.APHinzeE.Config"



I get this error:

Code:


[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax near ''.



I tried to escape the slash using / but then I get the error on that. How do I specify my account name with the slash?

View 1 Replies View Related

Adding A User To Only Access Data No Adds/edits/deletes

Oct 3, 2006

I'm hoping someone can get me pointed in the right direction

we have SQL 2005 and I need to add a user account to let some only view the data

no edits / adds / deletes ?



can any one help



thanks

David

View 5 Replies View Related

Transact SQL :: Adding Database - Single User Mode Freeze

Oct 5, 2015

I would like to add database to single user mode to enable broker. So, i have tried this:

ALTER DATABASE myDb SET SINGLE_USER WITH ROLLBACK IMMEDIATE
ALTER DATABASE myDb SET ENABLE_BROKER
ALTER DATABASE myDb SET MULTI_USER

But the query works more than half an hour then i have stopped it. i guess it has infinite loop, I get also many of this messages:

Nonqualified transactions are being rolled back. Estimated rollback completion: 0%.

There is no other transaction also there is no other user connections. So, what happens?

View 5 Replies View Related

Problem With NT Authenticated Logins After Migrating To AD!!!!!!!

Sep 16, 2004

I have a developer who created a DTS package using an NT authenticated ID. Now that we've migrated the SQL Server to another Domain in Active Directory, I am showing the following error for his jobs:

"The job failed. Unable to determine if the owner (DomainUSer) of job EmployeeDump has server access (reason: Could not obtain information about Windows NT group/user 'DomainUSer'. [SQLSTATE 42000] (Error 8198)).

When I went to check and see what the permissions problem might be, I noticed that all of my NT Authenticated ID are broken after migration - in other words, I can add the Active Directory NT ID's to the SQL Server instance, but I cannot give these ID's permissions to databases because it says they already exist??? I know if I have a sql login that is 'orphaned', I can use "sp_change_users_login" to fix it, but I think I read that this won't work for NT authenticated IDs.

IS there a way to fix this short of dropping ALL of my NT authenticated logins and recreating them????????

View 3 Replies View Related

SQL Security :: Adding A Windows Login Did Not Permit Access To End User Databases

Oct 24, 2015

Deleting a Login from a server instance and adding it back did not show that the login was still mapped to databases. In SQL Server 2008, adding a Windows Login did not permit access to end user databases until the Windows Login was mapped to various databases. In SQL Server 2012, once a Windows Login is added to SQL Server Security, it may access ANY end user databaseWe use the following to circumvent this problem, Windows Login by Windows Login: DENY VIEW ANY DATABASE TO [TESTTest1]

View 6 Replies View Related

Newbie Problems Adding ASPNET User To SQL Express Logins (Vista)

Apr 30, 2008



Hello,

I am trying to create an ASPNET Login for a SQL Server express Database (As Installed via Visual Studio) so my ASP Web Applications can invoke the Database. But SQLServer Managemnt Tool is not recognising any ASPNET user names I try.
I am trying to add via Microsoft SQL Server Management Studio Express, but get an error
" An Object (User or Built-in Security principal) with the following name cannot be found "mycomputerASPNET". "

Any obvious reason why ASPNET is not being recognised as a Login object object

Unfortunately I am on VISTA and IIS7 ( I have enabled, and checked that ASP Applications Run.)

- The process works OK on my other XP machine, ASP.NET via IIS 5.1, which seems more straightforward to set up.


Any help Appreciated, Since I am really stumped

Cheers

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved