sql-server-express

Generating Database Scripts in SQL Server Express

I generate change scripts for my database to keep it under source control, and a strange thing happens every time: I have a FlowFolder table, and clicking Generate Scripts creates the following two scripts: dbo.FlowFolder.Table.sql: USE [NC] GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO SET ANSI_PADDING ON GO CREATE TABLE [dbo]....

How to fill a varbinary(MAX) column with a default image for all the records in SQL Server 2005 Express

I want to fill the varbinary(MAX) column of a SQL Server database table when ever a new record is created with a default picture. How do I do this using a trigger or in that case by any other means? Any help is highly appreciated. Thank You This is the T-SQL code I have tried: SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ALTER TR...

Connecting to SQL Server using Delphi and dbExpress

I use RAD Studio 2010 including latest updates 4 and 5, my database is SQL Server Express. I set up a TSQLConnection but it won't connect, error message is "DBX-Error: the driver could not be initialized correctly. A client library may be missing, may not be installed correctly, or may have the wrong version" (error messagetranslated fr...

How to make a DB user have certain database role membership non interactively in SQL Server Express 2008

Dear ladies and sirs. First a little introduction. We have an SQL Server Express 2008 database, which schema is kept in the source control in the form of the scripts, originally created by opening the context menu on the database in the Management Studio and selecting Tasks|Generate Scripts .... Each developer has a local SQL Server ...

What problems will I cause by installing SQL Express as MSSQLSERVER?

As with the people in this feedback doc, Selecting the "Default Instance" option in SQL Server 2008 Express RTM has no effect, I had to install SQL Server Express 2008 twice before I realised what was I was doing. The installation defaults to "SQLExpress" even if you select Default Instance. What problems might I cause myself in the fu...

Getting a significant amount of data into a SQL Server (Express) database at time of deployment

For most database-backed projects I've worked on, there is a need to get "startup" or test data into the database before deploying the project. Examples of startup data: a table that lists all the countries in the world or a table that lists a bunch of colors that will be used to populate a color palette. I've been using a system where ...

Backup and Restore from SQL Server 2005 to 2008 express edition?

Hello there, I'm having a huge problem with a client. Their infrastructure blows, and most of the development done end up with mysterious errors(which only happen in their environment). What I'm trying to do is create a separate environment (a VPS) and push the application server and the database into this new environment, so they can...

SQL Server: enable remote connections without SSMS

I've got a SQL Server Express 2008 install on my web server, which by default does not allow remote connections (probably a good thing.) I opted not to install SQL Server Management Studio Express along with it for disk space and other reasons. I need to enable remote connections but any instructions I can find involve using SSMS to ch...

What SQL Server (Express) logins are needed for an ASP.NET MVC site?

For ASP.NET webforms, I have always needed the following server login: [machine_name\ASPNET]. Questions Is this requirement the same for ASP.NET MVC? If not, what do I need? Does it matter what version of SQL Server I'm using? (Currently, I'm running SQL Server Express 2005, but this could change in the future.) Does it matter what ve...

ASP.NET MVC wants me to store my SQL Server database files in the App_Data folder -- should I?

When creating a new database with SQL Server Express 2005, the database files (.mdf and .ldf) get stored in C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data by default. However, with the tutorials I've seen for ASP.NET MVC (e.g., Nerd Dinner), it seems to be common practice to keep the database files in the ASP.NET project's App...

SqlMetal Not Generating Views, Functions, or Stored Procedures

I am using the following commands as part of a cmd file: sqlmetal /server:localhost\SQLEXPRESS /database:DashBoard /dbml:DataClasses.dbml /namespace:DashBoard.Data sqlmetal /server:localhost\SQLEXPRESS /database:DashBoard /views /functions /sprocs /code:DataClasses.designer.cs /context:DataClassesDataContext /namespace:DashBoard.Data Da...

SQL server won't open DB created by Visual Studio

I've built an ASP.Net site in Visual Studio, and created the DB inside it (the .mdf file is in the APP_data folder). Now, when I want to deploy in the customer site, I think about maintaining the DB without open Visual Studio, and by using the SQL Server Express tools (back up etc.). I've searched how to do this, and learned that I sho...

SQL Server 2008 Express - sample database download?

is there a sample database for SQL Server 2008 that I can download to practice learning how to develop/use SQL Server...I have downloaded the SQL Server 2008 Express Edition, Visual Studio 2008, MS Web Dev 2008, ASP.NET 3.5..... ...don't think I can download anything else before I start learning how to use this stuff. Thanks guys... p...

Why don't I have permission to change this SQL Server Express 2005 password?

I have access to an installation of SQL 2005 Express. I probably installed it myself some time ago. But haven't used it in a while. I tried to access this instance via an 'sa' password I typically use for such local installs. However this password did not work. I double checked that mixed mode authentication is setup and that the sa u...

Running sql scripts against an attached database?

I've got an MDF attached to an instance of Sql Server 2008 Express, and I need to run some sql scripts against it to generate tables, indexes, etc. But I can't figure out how to get this to work. If I load the scripts in Visual Studio, it only allows me to connect to the server and run it against a database. I can't choose a different...

I cannot connect to SQL Server Express using VB.NET

Can someone tell me what I am missing? I am using this connection string to connect to my database and still it won't connect: Dim str As String = "Provider = .NET Framework Data Provider for SQL Server; Data Source=C:\Users\konin\Documents\UHMS\bin\Debug\UHMS.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True" This is...

i cannot connect to Microsoft SQL Server Database File (SqlClient)

I'm using Microsoft SQL Server Database File (SqlClient), name UHMS.mdf and I'm not able to connect to it. can someone help please. thanks. ...

Is SQL Server Express a serviceable database for a ASP.NET MVC web application

I am about to start building a ASP.NET MVC web application that relies on a database as it's backend (big surprise). As a student, I have access (via Dreamspark) to SQL Server 2008 Developer Edition, and with the default VS 2008 install, I have SQL Server Express 2005 installed already. Many of the examples on MVC I have seen use a loc...

SQL Server Express on the same machine, or external shared SQL Server Standard? (for an ASP.NET site)

I'm going to sign-up for a dedicated virtual machine from a renowned MS-centric web hosting company. The virtual machine has 1CPU and 1GB of RAM. I'll be running an ASP.NET website on it - the website is pretty simple (a few tables on the back-end DB) but must be as fast as possible. For the DB I have two options: 1) Install SQL Server ...

Security model (deployment) for MS Access application with SQL Server Backend

We have an application, consisting of an MS Access frontend (2007, mdb format), a few .net libraries and an SQL Server (2008) backend. I am working on an installer, which automatically installs the MS Access Runtime, our application, our libraries, SQL Server Express and configures everything. Clearly, the MS Access application and the ...