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


ADVERTISEMENT

Error 15401 Adding Login To SQL Server

Jul 23, 2005

I have a SAP Server running SQL2000 on Windows 2003.Recently I migrated the server from a NT4 Domain to a AD Domain usingADMT (with SID Migration for users) and everything seems ok.Now, after one month, I have to shut down the old NT4 domain and beforedoing it I have to replace the old logins in SQL with the correspondentusers in the new domain.I applied a script which returned Error 15401: Windows NT user or groupNEWDOMUser not found. Check the name again.I checked the KB article 324321http://support.microsoft.com/defaul...kb;en-us;324321I applied the suggestion to verify ifSELECT name FROM sysxlogins WHERE sid = SUSER_SID 'NEWDOMUser')returns a row, but this is not happening.Then I tried to create the new login from the Enterprise Manager. So Ibrowse for the user and I'm able to find it (It exists! It's the sameuser I use to login on the server) but when I apply the changes I getthe same 15401 Error.So it seems that the KB article is not useful because:1) There is no duplicate security identifier2) It's not an authentication failure because I can login and browsethe AD. Also if I choose another AD user it works!3) I don't think it's a case sensitivity problem because it happensalso from EM. By the way, I verified the SAMAccountName AD property ofthe user and the name is all UpperCase.I checked lots of posts dealing with this matter but they don't seem toapply.Any help would be greatly appreciatedThanksDave

View 1 Replies View Related

Error 15401 Adding Domain Group To SQL Server

Nov 9, 2006

I have tried rebooting the system, I have ran the script to look for duplicate sids and am still having the issue when trying to add a domain group to SQL. I get the Error 15401: Windows NT user or group'miTrust Legal' not found. Check the name again. Running SQL 2000 Std, with SP3a, and the collation is set to SQL_Latin1_General_CP850_BIN, which makes this instance case sensitive, and the group name is spelt right and am following the case sensitivity of the name as well.

View 10 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

Error 15401: Windows NT Group Or Group Not Found

Sep 25, 2003

I have a user in SQL Server with a NT login of Mike
I changed his NT account to Mikel in User Manager

Now when I try to add Mikel, Im getting error 15401.

Do I need to delete NT login in SQL Server 'Mike' account first ?..before adding 'Mikel' ?

Can I go into the Master database and just change Mike login to Mikel ?

Thank you

View 3 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

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

Login Failed For User , The User Is Not Associated With A Trusted Sql Server Connection. (microsoft SQL Server,Error:18452)

Aug 21, 2007

Login Failed for user , the user is not associated with a trusted sql server connection. (microsoft SQL Server,Error:18452)


hi ,
i am getting the above error message once in a while maybe two or 3 times a week , and then it goes away in 10 to 15 minutes or 5 minutes ,

our mode is set to mixed and we are able to connect and use both sql and windows , but once in a while , it will give us the above message when we try connecting throught sql server management studio client (using sql 05) using windows login , although it lets us connect using sql login while the windows login is denied, and after a while it lets us connect with both.

occurs randomly on some days , we run our servers on VM ware virtual machines using windows 2003 r2 enterprise 64 bit with sp2 with esx 301 virtual machine.

would appericate any feedback on this thanks

View 5 Replies View Related

Login Failed For User '' ..... Sql Server, Error: 18452 (The User Is Not Associated With A Trusted SQL Server Connection)

Nov 7, 2007

Hi

Last week I was receiving an error when trying to connect to two of our seven sql servers from my laptop via my domain admin account. The only fix was to have my laptop rebuilt and everything re-installed.

Today however another administrator is starting to have the same problem but to only one of the seven servers!
When that administrator uses my laptop with her domain admin account it works!?

What could possibly be going wrong with our laptops? We have not installed or changed anything.

The full error message we see:

Login failed for user ''. The user is not associated with a trusted SQL Server connection. (Microsoft Sql Server, Error: 18452)

The error being logged on the server: (two errors are logged each time)


SSPI handshake failed with error code 0x8009030c while establishing a connection with integrated security; the connection has been closed. [CLIENT: 53.35.165.148]


Login failed for user ''. The user is not associated with a trusted SQL Server connection. [CLIENT: 53.35.165.148]

View 16 Replies View Related

Entreprise Manager Error Message: [Microsoft][ODBC SQL ServerDriver][SQL Server]Login Failed For User '#####'. The User Is Not Associatedwith A Trusted SQL Server Connection.(28000,18452)

Dec 12, 2007

Can anyone give a quick description of the meaning of this message andwhat needs to be done to get a connection.I'm running DBArtisan with SQLServer 2000 client SP4 installed.I also get the same message with MS Enterprise Manager so this iscoming out of the actual ODBC connection attempt.Thanks in advance!

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

Error Login Failed For User ''. The User Is Not Associated With A Trusted SQL Server Connection.

Feb 18, 2008

All the research I found dealing with this problem is that the solution is to set SQLserver to mix mode.  I have SQL server already set to mix mode. I am not sure what else to do. Has anybody run into this problem?
my connection string: <connectionStrings>
<add name="ConnectionString" connectionString="Data Source= server name ;
Initial Catalog=FILESHAREDB.MDF;
Integrated Security=false;"providerName="System.Data.SqlClient"/>
</connectionStrings>
 
Server Error in '/SendItNow' Application.


 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 ''. The user is not associated with a trusted SQL Server connection.Source Error:



Line 41:
Line 42: 'open the connection and execute the stored procedure
Line 43: mConnection.Open()
Line 44: mResourceID = mCommand.ExecuteScalar()
Line 45: mConnection.Close()Source File: H:MIS DepartmentIntranetSendItNowApp_CodeDalResourceDB.vb    Line: 43 Stack Trace:



[SqlException (0x80131904): Login failed for user ''. The user is not associated with a trusted SQL Server connection.]
System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +800131
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +186
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1932
System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK) +33
System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject) +172
System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +381
System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +181
System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +173
System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +357
System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +30
System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) +424
System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) +66
System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) +494
System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +82
System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.SqlClient.SqlConnection.Open() +111
ResourceDB.SaveResource(String filename, String fromContactEmail, String toContactEmail, String message, Int32 ID) in H:MIS DepartmentIntranetSendItNowApp_CodeDalResourceDB.vb:43
Resource.SaveResource(String filename, String fromContactEmail, String toContactEmail, String message) in H:MIS DepartmentIntranetSendItNowApp_CodeBllResource.vb:31
ContentFiles_Default.ImageButton1_Click1(Object sender, ImageClickEventArgs e) in H:MIS DepartmentIntranetSendItNowContentFilesDefault.aspx.vb:33
System.Web.UI.WebControls.ImageButton.OnClick(ImageClickEventArgs e) +86
System.Web.UI.WebControls.ImageButton.RaisePostBackEvent(String eventArgument) +115
System.Web.UI.WebControls.ImageButton.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) +1746



Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

View 2 Replies View Related

[298] SQLServer Error: 18452, Login Failed For User ''. The User Is Not Associated With A Trusted SQL Server Connection.

Mar 11, 2008

I received the above error yesterday and haven't been able to trace it to any job or process running. We haven't implemented any changes to the server in the past few months, and it doesn't look to be a user-established connection, since the Client IP Address of the SSPI handshake error is from the server itself.

I logged this set of messages in SQL AgentServer error log:


Date 10.03.2008 6:15:19 PM
Log SQL Agent (Current - 10.03.2008 6:15:00 PM)

Message
[298] SQLServer Error: 18452, Login failed for user ''. The user is not associated with a trusted SQL Server connection. [SQLSTATE 28000]

Date 10.03.2008 6:15:19 PM
Log SQL Agent (Current - 10.03.2008 6:15:00 PM)
Message
[382] Logon to server '<server>' failed (ConnAttemptCachableOp)

Date 10.03.2008 6:15:19 PM
Log SQL Server (Current - 11.03.2008 2:32:00 PM)
Source Logon
Message
Error: 17806, Severity: 20, State: 2.

Date 10.03.2008 6:15:19 PM
Log SQL Server (Current - 11.03.2008 2:32:00 PM)
Source Logon
Message
SSPI handshake failed with error code 0x80090304 while establishing a connection with integrated security; the connection has been closed. [CLIENT: <IP Address>]

Date 10.03.2008 6:15:19 PM
Log SQL Server (Current - 11.03.2008 2:32:00 PM)
Source Logon
Message
Error: 18452, Severity: 14, State: 1.

Any help in explaining this would be greatly appreciated.

View 8 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

Error On Adding New Server Login

Oct 11, 2004

When I tried to add a new login to the server and after assigning DB Roles,
I am getting the error message that the role has been already added to the user. I think this username has already been in the system earlier. It is in the sysuser table. I tried to delete the roles to which this user has permissions. But still I am getting this error. I am not sure where else it is stored. How can I delete this username completely from all Databases and reassign this userid in the server.
Please advise.

View 2 Replies View Related

Link Server Error: Login Failed For User 'Domainuser'. (Microsoft SQL Server, Error: 18456)

Oct 18, 2007


Hi,

I am trying to create a linked server between 2 SQL Server 2005 boxes.
When I create the linked server I specify a login for the connection.
The strange part is that I get the following error when it goes to test the connection:

The test connection to the linked server failed
Login failed for user 'Domainuser'. (Microsoft SQL Server, Error: 18456)


I can use the SQL mangement studio to conenct to the database using this same login.
The login has all the server roles assigned to it also.

Can anyone shed some light as to what may be the problem?


Thanks,

View 5 Replies View Related

Error : Cannot Open User Default Database. Login Failed. Login Failed For User 'server/user'

Nov 22, 2007



i'm using the Enterpirse library logger to write logs into a database.
When choosing connection string i choose the database i want in the "connection properties" dialog box and
push 'Test connection' button.
everything goes well.

then i open the SQL Server Management studio express and connect to the databse to check some things,
from that point on , when i push the 'Test Connection' button in the Enterprise library i get the error:


"cannot open user default database. Login failed. login failed for user My'server/MyuserName'"


even when i close the sql server manager , it is still stuck - the connection test doesn't work anymore....
it only work when i restart the computer.

why ?

View 3 Replies View Related

SQL Server 2014 :: Error In Adding Condition In Query

Apr 4, 2015

Following is a working code

declare @dte as datetime='2015-04-01'
declare @StDt as Datetime = DATEADD(mm,DATEDIFF(mm,0,@dte), 0)
declare @EnDt as datetime = DATEADD( DD, -1, DATEADD(mm,DATEDIFF(mm,0,@dte) + 1, 0));
DECLARE @query AS NVARCHAR(MAX);
create table #bus_master(bus_id int,bus_name varchar(50),uname varchar(50))
insert into #bus_master values(100,'A','lekshmi')

[Code] ...

I am getting the output correctly. My requirement is i want to write a condition here
JOIN busdetails b ON m.bus_id = b.bus_id

I want to write this statement as
JOIN busdetails b ON m.bus_id = b.bus_id and m.uname='lekshmi'

When I tried this code I am getting error.

View 3 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

Error 15185: There Is No Remote User 'sa' Mapped To Local User '(null)' From The Remote Server 'DTS_FSERVER'.

Nov 10, 2006

I am trying to add a linked server from a AMD x64 server (Windows 2003) with SQL Server 2005 64 bit to a Server running SQL 2000. These are not in the same domain.

I can create a linked server using the option "Be made using the login's current security context" but can not when trying to specify the security context, i.e. sa and the sa password. When I try I get the following message:

Msg 15185, Level 16, State 1, Procedure sp_addlinkedsrvlogin, Line 98
There is no remote user 'sa' mapped to local user '(null)' from the remote server 'DTS_FSERVER'.

I have several other x64 server that I have no problem creating a linked server and specifying sa and the sa password.

The problem with using "the login's current security context" option is that I get an error when trying to run any Jobs against the linked server. The job fails withe the following error:

Executed as user: NT AUTHORITYSYSTEM. Access to the remote server is denied because no login-mapping exists. [SQLSTATE 42000] (Error 7416). The step failed.

I'm sure the two errors are related. Any ideas what is going on?

View 7 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

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

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 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

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

Failed To Generate A User Instance Of SQL Server Due To Failure In Retrieving The User's Local Application Data Path. Please Make Sure The User Has A Local User Profile On The Computer. The Connection Will Be Closed

Dec 7, 2006

This is my first time to deploy an asp.net2 web site. Everything is working fine on my local computer but when i published the web site on a remote computer i get the error "Failed to generate a user instance of SQL Server due to failure in retrieving the user's local application data path. Please make sure the user has a local user profile on the computer. The connection will be closed" (only in pages that try to access the database)
Help pleaseee

View 3 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







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