Hi guys, I am facing a confusing problem, whenever i select the add new item tab and choose add sql database, it reads an error stating 'Connections to sql server files require SQL server 2005 to be functioning properly, please verify the installation of the component or download it'
The thing is, I have sql server 2005 properly installed on my pc and at the same time, whenever I choose to create a new connection from the server connection or in setting up a connection to the existing databases, I do not face any problem, so why is this issue occuring over here, I have no idea, thanks to anyone willin to resolve!
When adding/removing tables in SSMS 2016 CTP2, I keep tripping into:
Index was outside the bounds of the Array
When editing a SQL Server 2014 Database.
If I use the SSMS for SQL 2014, the error is not happening. Possibly a reintroduced bug. Tried to use the Connect site to submit, but it says I am not enabled to use this area.
In trying to upgrade my sql express install from express to developer edition, I ended up having to delete all things express from my computer and do a clean install of developer edition (as i installed developer edition initially over sql express but this didnt seem to work; express edition still appeared in add remove programs etc). Anyway so i blew away the install and have a clean install of developer edition. Now when I create a new website in Visual Studio 2005 and try to add a database to the project, it gives me an error stating that i need to have sql server express 2005 installed to function properly... Do i need to have express AND developer edition of sql installed to do this? I would think developer edition of sql would enable me this functionality...http://img277.imageshack.us/img277/4228/sqlerrorie2.jpgThanks!It is also worth noting that I get the dreaded remote connection error when trying to connect to a db that I used to be able to connect to when I was using sql express (the aspnetdb database that is created when you user their membership stuff)"An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) "However, I did the following successfully:1. create a database using the sql management studio2. added a table and some data to it3. threw a dataset into the website4. added a gridview to a page in the website, pulling data from the dataset5. and the website runs successfully populating the page with data...fyi: My sql services: http://img158.imageshack.us/img158/2020/sqlserviceshj6.jpg
I am new to ms SQL. I only have the use of the Enterprise Manager. Creating tables I understand. However I am confused on how to add data to a table or view the data in a table. Can this be done through Enterprise Manager? If I am adding a large amount of data do I have to use the query window. This seems like a tedious method. In Access yo have a form basically pop up where you can type in the record sets. Any advice would be appreciated! Sincerely, Bill Bequette
Hi Guys, I know this is a little off the subject of ASP.net but I am using some code behind in C#. I am a real novice at this and so it may appear to be a simple question but Im trying to add a number to the database from a textbox but it is having issues as the Storenum is an int and it wants a string. Can anyone help? I know I need to write .tostring somewhere but can't work out where. My code is below. Thanks in advance. =) public partial class _addstore : System.Web.UI.Page {protected string Location; protected string Telephone;protected string Prefix; protected int StoreNum;protected string myConnectionString;protected void Page_Load(object sender, EventArgs e) { Location = "default";Telephone = "default"; Prefix = "default";StoreNum = "0";myConnectionString = "Data Source=.\SQLEXPRESS;AttachDbFilename=C:\inetpub\wwwroot\HOF\App_Data\HOF.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True;";
Hi, I am so very new at using asp and my problem is that i have created a new access database and I am unable to connect to it. I am using the desktop engine and I can connect to all the sample database's fine. I've tried using the osql statments at the command prompt and after I am granted login and try to grant access to my new database called 'Assets' it tells me that i do not have access or permission to this database. If anyone can help me I would so so appreciate it (I need idiot instructions :) ).
Hi.. When I try to add new item "SQL Data Base" the following error generate: Failed to generate a user instance of SQL server due to a failure in starting the process for the user instance. The connection will be closed. what is mean? what is its reason? how I can solved? Please help me as soon as possible.. Thanks..
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.
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.
I've been getting what I think is a bizarre error message whilst trying to create a foreign key between two tables.
tblDailyComments has a primary key of DiaryID tblDailyOperatingData has a column DiaryID.
Both are Int (4).
Yet when I run the following:
ALTER TABLE tblDailycomments ADD CONSTRAINT FK_tbldailycomments_tblDailyOpData FOREIGN KEY REFERENCES tblDailyOperatingData(DiaryID)
I'm getting the error message:
Server: Msg 8139, Level 16, State 1, Line 1 Number of referencing columns in foreign key differs from number of referenced columns, table 'tblDailycomments'.
I also tried to create the relationship in a database diagram and this brought back errors as well.
The subscriber was able to get the snapshot ok, then synchronise fine
However after adding an article to the publication and recreating the snapshot I get this error now at the subscriber
Microsoft.SqlServer.Replication.ComErrorException (0x80004005): A failure occurred when accessing 'usp_misc_dailyTasks_3.sch' due to an operating system error [2='The system cannot find the file specified.'] during Web synchronization. Ensure that the -InternetLogin user when using basic authentication and the user running the merge when using Windows integrated authentication has been granted access to the snapshot share.
at Microsoft.SqlServer.Replication.MergeSynchronizationAgent.Run()
The key properties when synchronising are as follows:
I have a clr assembly that access the internet via Sockets and file access. This require me to set the Assembly permissions level to External.
There are lots of messages on the net regarding this issue. none have worked for me.
Currently I'm trying to install the assembly with "sign the assembly" checked, createing a strong name key file.
When I run the installation I get the following message from the server
"Create failed for SqlAssembly 'xxx'.(Microsoft.sqlServer.Smo)
an exception occured while executing a Transact-SQL statement or batch
(Microsoft.SqlServer.ConnectionInfo)
A severe error occured in the current command. The results, if any, should be discarded.
This is the messag I get.
The following link does not display any usefull information.
TITLE: Microsoft SQL Server Management Studio ------------------------------
Create failed for SqlAssembly 'KBTTriggers'. (Microsoft.SqlServer.Smo)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+SqlAssembly&LinkId=20476
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
A severe error occurred on the current command. The results, if any, should be discarded. A severe error occurred on the current command. The results, if any, should be discarded. (Microsoft SQL Server, Error: 0)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQLServer&EvtID=0&LinkId=20476
I am new to ADO.NET and have a emergency problem to slove.
I am using VS 2005 to open a solution that created by previous VS. After the solution is upgraded by VS, I was gonna add a data souce to the form. The destinated database is a sample called Northwind. But right after I want to add a table called "employee" as the object database in dataset, I got an error "error using the dropdown: Could not get type information for 'Getting_Started.NorthwindDataSet'"
I created a test form and did the same procedure but got no error at all. So I guess there must be something wrong with using VS 2005 to open solution created by previous VS.
Hi guys, I need some help again please. On my page load, I need the following done... I have a label control that must display a certain numeric value. This value must be the sum of an array of values that must be retreived from a table ("Details") with the column name "DealValue" but only where the column "ConsultantID" = txtConsultant.text I understand the select statement, but I don't know how to "run" through the table to add all the values. Can someone please help me with this and how I would construct the MSSql select statement for this. Thanks again
HI, I was going across the SQL tutorials, sql tutorial # 2 am coming across a preliminary problem. When I click the 'add new item' tab from the website menu, and choose 'SQL Database', the connection is not setup and the error reads as follows: Connections to SQL server files require SQL server 2005 to function properly.Please Verify the installation of the component or download the URL:.....
Now I have the necessary data connections working in my database, but I just can't figure out why is this going wrong.If somebody can literally spoonfeed me here, I'll be grateful, I am a pure newbie here, thanks!!!
I have DateCreated with datetime datatype in my SQL Express 2005. I'd like to add the record to my Task table so I have a form in my ASPX and create a button event in my ASPX.CS here is the code protected void Button_AddTask_Click(object sender, EventArgs e) { SqlDataSource newTask = new SqlDataSource(); newTask.ConnectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ToString(); newTask.InsertCommand = "INSERT INTO [Task] ([MemberAccountName], [Title], [Place], [TaskDetail],[DateCreated]) VALUES (@MemberAccountName, @Title, @Place, @TaskDetail,@DateCreated)"; newTask.InsertParameters.Add("MemberAccountName", User.Identity.Name); newTask.InsertParameters.Add("Title", TextBox_Title.Text); newTask.InsertParameters.Add("Place", TextBox_Place.Text); newTask.InsertParameters.Add("TaskDetail", TextBox_Detail.Text); newTask.InsertParameters.Add("DateCreated",DateTime.Now.ToString()); newTask.Insert(); Response.Redirect("Default.aspx"); }but I got this errorArithmetic overflow error converting expression to data type datetime.The statement has been terminated.Any idea?
I'm new at this and wondering if someone would have the heart to help.I want to know how to add data into a database. Here's the details:I have a sqldatasource( sqldatasource1) attached to a database with a table named customers.The table(customers) has one field named 'Name' with datatype varchar(50)I have a textbox (textbox1) and a button (button1)I want to insert the text into textbox1 into my database. how can i do that?
I have a problem when I try to add new SQL Database. I am using Visual Web Developer 2005, and when I try to add new item which new SQL Database, it then asks me if I want to create a folder called 'app_data' to store the database. I click on yes. Then the error message come out:
Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.
Anybody please help me out.... thanks a lot in advanced!!
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.
When a new Database is created ( some , not all. All that begins with 'PW' ) i want to add a windows-usergroup to it so they can access the DB. Normally I could do this by adding this user to the model-db but it's not for all DB's that are added (The other DB's must not be accesible for this usergroup ). The DB's are added by an External App so I have no control over it.
So I was thinking, no problem we can just add a trigger to the master..sysdatabases table and add if necessary the permissions. Not -> Even with allowupdates = 1 you cannot add a trigger to a system table ( a bit overprotection from ms, should be allowed if you know what you are doing ).
I would like to avoid running a job every x time to look if a new DB has been added, the DB must be available within minutes after creation.
Hi,I'm trying to create a page where a user can search the database according to some criteria and get back the result in the form of a GridView. Also, the user has the option of saving the criteria to another table in the database by assigning it a name so that it can be retrieved easily in the future.I have the search and display part working, however, saving the criteria to the database is giving problems for some reason.Given below is my stored procedure to add the info to the db. SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ALTER PROCEDURE [dbo].[AddToReport] (@ReportName varchar(100), @ProjID varchar(300), @DeptCode varchar(20), @ProjType varchar(20), @ProjectTitle varchar(300), @ProjectManagerID int, @DateRequested datetime, @DueDate datetime, @ProjectStatusID int)
AS SET NOCOUNT ON DECLARE @Dept varchar(50) DECLARE @err int
BEGIN TRANSACTION
IF @ReportName IS NULL BEGIN RETURN -1 END ELSE BEGIN IF @DeptCode IS NOT NULL BEGIN SET @Dept = REPLACE(CONVERT(char,@DeptCode),'.','') END SET @err = @@ERROR
INSERT INTO dbo.tbl_Report (ReportName, ProjID, DeptCode, ProjType, ProjectTitle, ProjectManagerID, DateRequested, DueDate, ProjectStatusID) VALUES (@ReportName, @ProjID, @Dept, @ProjType, @ProjectTitle, @ProjectManagerID, @DateRequested, @DueDate, @ProjectStatusID); IF @err<>0 BEGIN ROLLBACK TRANSACTION RETURN @err END END COMMIT TRANSACTION Given below is the relevant codebehind. This is how the values are initialized: Dim newManager As New ListItem newManager.Text = "Choose a Manager" newManager.Value = 0 projectManagerDDL.Items.Add(newManager)
Dim newDept As New ListItem newDept.Text = "Choose a Department" newDept.Value = "" deptCodeDDL.Items.Add(newDept)
Dim newID As New ListItem newID.Text = "Choose a Project" newID.Value = "" projIDDDL.Items.Add(newID)
Dim newStatus As New ListItem newStatus.Text = "Choose a Status" newStatus.Value = 0 projectStatusDDL.Items.Add(newStatus)
Dim newDateRequestedMonth As New ListItem newDateRequestedMonth.Text = "Month" newDateRequestedMonth.Value = 0 dateRequestedMonthDDL.Items.Add(newDateRequestedMonth)
Dim newDateRequestedDay As New ListItem newDateRequestedDay.Text = "Day" newDateRequestedDay.Value = 0 dateRequestedDayDDL.Items.Add(newDateRequestedDay)
Dim newDateRequestedYear As New ListItem newDateRequestedYear.Text = "Year" newDateRequestedYear.Value = 0 dateRequestedYearDDL.Items.Add(newDateRequestedYear)
Dim newDueDateMonth As New ListItem newDueDateMonth.Text = "Month" newDueDateMonth.Value = 0 dueDateMonthDDL.Items.Add(newDueDateMonth)
Dim newDueDateDay As New ListItem newDueDateDay.Text = "Day" newDueDateDay.Value = 0 dueDateDayDDL.Items.Add(newDueDateDay)
Dim newDueDateYear As New ListItem newDueDateYear.Text = "Year" newDueDateYear.Value = 0 dueDateYearDDL.Items.Add(newDueDateYear) This is the submit code: Protected Sub saveButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Dim connString As String Dim con As SqlConnection
Dim cmd As SqlCommand = New SqlCommand() cmd.Connection = con
If (([String].IsNullOrEmpty(reportNameTextBox.Text) = False) Or reportNameTextBox.Text <> "Enter Report Name") Then cmd.Parameters.Add("ReportName", SqlDbType.VarChar, 300).Value = reportNameTextBox.Text End If
If ([String].IsNullOrEmpty(projIDDDL.SelectedItem.Value)) = False Then cmd.Parameters.Add("ProjID", SqlDbType.VarChar, 30).Value = projIDDDL.SelectedItem.Value End If
If ([String].IsNullOrEmpty(deptCodeDDL.SelectedItem.Value)) = False Then cmd.Parameters.Add("DeptCode", SqlDbType.VarChar, 20).Value = deptCodeDDL.SelectedItem.Value End If
If (typeRBL.SelectedItem.Value <> "All") Then cmd.Parameters.Add("ProjType", SqlDbType.VarChar, 20).Value = typeRBL.SelectedItem.Value End If
If ([String].IsNullOrEmpty(projectTitleTextBox.Text)) = False Then cmd.Parameters.Add("ProjectTitle", SqlDbType.VarChar, 300).Value = projectTitleTextBox.Text End If
If CInt(projectManagerDDL.SelectedItem.Value) <> 0 Then cmd.Parameters.Add("ProjectManagerID", SqlDbType.Int).Value = CInt(projectManagerDDL.SelectedItem.Value) End If
If (dateRequestedDayDDL.SelectedItem.Value = 0 Or dateRequestedMonthDDL.SelectedItem.Value = 0 Or dateRequestedYearDDL.SelectedItem.Value = 0) Then Dim dateRequested As New DateTime dateRequested = Nothing Else Dim dateRequested As New DateTime(dateRequestedYearDDL.SelectedValue, dateRequestedMonthDDL.SelectedValue, dateRequestedDayDDL.SelectedValue) If (dateRequested) <> Nothing Then cmd.Parameters.Add("DateRequested", SqlDbType.DateTime).Value = dateRequested End If End If
If (dueDateDayDDL.SelectedItem.Value = 0 Or dueDateMonthDDL.SelectedItem.Value = 0 Or dueDateYearDDL.SelectedItem.Value = 0) Then Dim dueDate As New DateTime dueDate = Nothing Else Dim dueDate As New DateTime(dueDateYearDDL.SelectedValue, dueDateMonthDDL.SelectedValue, dueDateDayDDL.SelectedValue) If (dueDate) <> Nothing Then cmd.Parameters.Add("DueDate", SqlDbType.DateTime).Value = dueDate End If End If
If (projectStatusDDL.SelectedItem.Value) <> 0 Then cmd.Parameters.Add("ProjectStatusID", SqlDbType.Int).Value = CInt(projectStatusDDL.SelectedItem.Value) End If
Try con.Open() cmd.ExecuteNonQuery() Response.Write("Report Saved") Catch ex As Exception Response.Write(ex) Finally con.Close() con.Dispose()
End Try
Catch ex As ApplicationException Response.Write("Could not load the database") End Try
End Sub The only absolute requirement when saving to the table is the ReportName. All the other criteria can be NULL. If I don't select and values and try to save the values, I get an error:System.Data.SqlClient.SqlException: Procedure or function 'AddToReport' expects parameter '@ProjID', which was not supplied. at System.Data.SqlClient.SqlConnection.OnError... etc If I choose the ProjID (thus giving it a value), I get the following error:System.Data.SqlClient.SqlException: Procedure or function 'AddToReport' expects parameter '@DeptCode', which was not supplied. at System.Data.SqlClient.SqlConnection.OnError... etc and so forth. I'm guessing it's a problem of NULLs somewhere, but I'm not sure. Thanks.
I am trying to setup an AG on a cluster, I was able to define where I want my replica, but I need to setup the ip for the listener of that one
When I am adding the Ip at the listener I am getting the following message:
The Windows Server Failover Clustering (WSFC) resource control API returned error code 5057. The WSFC service may not be running or may not be accessible in its current state, or the specified arguments are invalid. For information about this error code, see "System Error Codes" in the Windows Development documentation.
The attempt to create the network name and IP address for the listener failed. The WSFC service may not be running or may be inaccessible in its current state, or the values provided for the network name and IP address may be incorrect. Check the state of the WSFC cluster and validate the network name and IP address with the network administrator. (Microsoft SQL Server, Error: 41009)
Browsing around I found this guide: [URL] ......
And I make sure that the cluster has permissions to "Read all properties", "Create Computer Objects", even to "Create all child" permissions
I also added those permissions to the account that starts sql at that cluster and I am logged as that and I am still getting the error....
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
I am trying to add a data driven subscription to my report. When I get to the screen to enter the Delivery Query, I enter the stored procedure (GetStatusReportData) in the query box. When i try to validate, I get a "Query is not valid" error. If I replace the stored procedure name with a generic query (select * from jobs), it works fine.
Is there some sort of syntax I need to use to enter a stored procedure here? I have used "exec GetStatusReportData" and that did not work either.
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.
My report, which has a matrix and a chart work fine. Then...
I click on the Data tab, drag a measure into the results grid. At this point I haven't added the new measure to the matrix or anything in Layout.
I click the Preview tab and get the following message: "The definition of the report XXX is invalid. More than one data set, data region, or grouing in the report has the name 'YYY'. Data set, data region and grouping names must be unique within a report.
Ok, I get the point. But why and how would adding a measure give me this issue? Where can I even find where this is being duplicated?
The message refers to a name that is a parameter, and I don't see anything in there that might cause this.
i get the following error message during package validation:
OnError ErrorCode -1073451000 Source DataFlow SubComponent DTS.Pipeline Description The package contains two objects with the duplicate name of "compone nt "OLE DB Command" (719)" and "component "OLE DB Command" (701)".
Hello All, So I have created a form using VB. I put the add, del, edit, save .....etc buttons. When I add and click on save the database does not get updated after closing the form. I remember in vb6 we used to us dataname.update but the new VS 2005 does not have this function "update"?
When I try to build my solution, it tells me that "SQLCommand" is not defined.
What's the problem?
Sub submitButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) 'If Page.IsValid Then Try Dim MySQL = "addCustomerSQL" Dim cmd As New SQLCommand("addCustomerSQL", dbConn) cmd.Commandtype() = CommandType.StoredProcedure cmd.Parameters().Item("@username").Value = userText.Text cmd.Parameters.Item("@password").Value = passText.Text dbConn.Open() cmd.ExecuteNonQuery() dbConn.Close()