Best Practice-working With SQL Express Database

Mar 13, 2006

Hi,

I am new to working with Database using .net C#. i will really appreciate if someone can point me to a link where i can find best practices of working with sql express database with my c# web service applications.

preferably i would like to have answers for:

- to have one db or to have one for testing and one real db?

- db security

- use windows authentication or db user authentication

etc.

View 1 Replies


ADVERTISEMENT

Good Practice When Working With Objects Using SQLServer As A Secure Store.

Oct 11, 2006



I'm sure this has been asked plenty of times before, so I'm after a link to a good answer.

I have tens of thousands of milk crates, holding dozens of different types of milk in hundreds of locations. I am used to working with objects but not databases. For this situation however I want the security of SQLServer transactions to track, for example, when a robot moves a crate from one location to another.

I am thinking of using SQLServer as a store. On startup I want to get my ecosystem of objects out of the store. While I am running, I'll just use objects. When I change an object property I want it to securely persist. I don't want to snapshot the whole menagerie of object states, just update the values that changed. Which will sometimes include the addition or deletion of objects. How do I do this? Is there an example somewhere that does this (or approximately this)?

I use VB and have Visual Studio 2005. (Which, by the way, is stunning. I thought all that "you will use less time and code more and better" talk was just hype. But its for real. Amazing product.)

tia

John









View 1 Replies View Related

SQL Express Database On Production Server Not Working

Aug 6, 2007

Hi all,
I have a site which used a SQL Express database. On my development machine, it works perfectly. As soon as I move it to the production machine, it doesn't work at all. I am pretty confused by what is going on and I really don't want to install Visual Studio on my production machine just to debug it. I am hoping someone might have an idea what could be happening.
Oh, and I have tried setting Everyone to Full Control on the App_Data directory just to test. Still breaks. Below is my web.config connection string:
<connectionStrings>   <add name="database_sqlexpress" connectionString="Data Source=.SQLEXPRESS; AttachDbFilename=|DataDirectory|MyDatabase.mdf; integrated security=true; user instance=true"/></connectionStrings> 

View 2 Replies View Related

SQL Server Express Is Working - What Tool Do I Use To Create Database And Tables?

Aug 16, 2006

Hello,

I have SQL Server Express working however I don't see any tools to create a database and tables.

I am trying to create a database to store stock quotes that I will input from a c# program.

What tool should I use to design the database?

Thank you!
Toben

View 4 Replies View Related

New Database: Best Practice

Jan 24, 2007

Good Morning,
I work for a company that has sees alot of people come and go. The one thing I have noticed is that people use their admin accounts to log into SQL and create sp, views and databases.When the user leaves I am stuck with all these objects that are owned by somone no longer working for the company.
So my question to you guys is: What is the best practice to use in creating new objects?
Thanks for your guru-ness!

View 3 Replies View Related

Best Practice For Database Migration

Nov 17, 2006

Can you tell me what is the best practice for SQL database migration fromone DB server, to another one, new DB server. The old DB server will beremoved.1. Backup from old and restore all databases on the new server2. Export data and copy/import on a new server3. Something else...Thanks in advance for any good advice...Regards

View 2 Replies View Related

Upgrading A Database (good Practice)

Mar 5, 2008

hi experts,
i have a postcode database that i need to update. the database cnotains of 6tables, the file i ahev has all the information at once, so i have to organize it and insert records into the appropriate tables.
this is the first time i'm doign this so i would like to know what the best way to do? do i need to create a stored procedure or a script, or may be something special and efficient that i do not know yet.
any advise will be very appreciated
thanks in advance

View 1 Replies View Related

Best Practice For Database Design Scenario

Sep 26, 2007

Hi,

I'm currently building a database that is going to have at least 6 different types of users accessing it via a web application.

A user will have different information collected about them. A few of of the users will have the same or similiar information collected about them.

I will be using role based authentication.

Now my query is this;

Scenario 1:
Would it be a good idea to keep all the users common information in one table. Ie. thier username,email,password,name. Then create a tblDetails for each type of user that would contain the different data. That way i can just check one table to verify thier login credentials.

OR
Scenario 2:
Would it be best to create a seperate table for each type of user and then log them in based on the credentials stored in each type of users respective table.

Hope this is clear. I'm leaning towards scenario 1, although I've used scenario 2 before. Just wondering which would be preferred.

Cheers
RobC

View 2 Replies View Related

Best Practice For Upgrade Of Live Hosted Database?

Sep 11, 2007

I'm not sure this is the exact forum in which to ask this question, so if there is a more appropriate forum, please point me in that direction.

Basically I'm looking for advice and best practices for dealing with an upgrade plan for a hosted database. Here is the situation:
- Hosted software application (.Net)
- Uses SQL Server 2005
- When we upgrade the software application to a new version, there will be schema and data changes that need to be applied to the database
- For the software application, we have considered upgrading an offline machine and then switching old one instantaneously.
- For the database, I'm trying to figure out if we can keep everything live for upgrades, or if we should have a small amount of scheduled downtime to upgrade.

So we have identified 2 basic directions:
1) Keep the database live and apply the new script changes just after the application software is upgraded. This means zero downtime, but we'd have to design and test our application to be backward compatible, so that the new version of the application code could handle both the new schema design, and the old schema design. It seems that this option would add a huge amount of complexity because we would essentially be testing a 3rd app/schema combination.
2) Take a small amount of scheduled downtime and upgrade the application code and database all at once.

Obviously option #2 is the most desirable from a development process point of view, and #1 is the most desirable option from a business point of view (zero downtime).

So, I'm looking for some advice on this. Do most people take the whole system down? Are there 100% live systems that deal with this? Are there other approaches I'm not considering?

Any information would be greatly appreciated. Thanks.

View 4 Replies View Related

Date And Time Best Practice - Storage In SQL Server Database

Jul 27, 2007

With regards to time zones, daylight savings, and web users, is there a best practice for storing date & time information in a database?
For example, my databases are hosted in Time Zone A, but the web users are in Time Zone B.  Then, when I create a rss feed (which is displayed in GMT), I add a third time zone into the mix for the same data.  To date (no pun intended), I have been entering the date/time data in the time zone of the database server (Time Zone A), and then converting it using an application setting in the web.config file (i.e. TimeZoneBOffset = -1, GMTOffSet = -5).  In other words, each time I display a date I calculate what it should be using the time-zone offset in the web.config.  This also enables me to account for changes in day light savings, etc.
My concerns are three fold:  1. What if I move the database to another server and the time zone changes?  2. Right now the users are in only 1 time zone.  If I expand it to several then the offset will have to be by users, which is do-able, but something I haven't had experience with in the past.  3. It is likely more efficient to calculate the time zone once on input into the DB, rather than in each use like I'm doing now.  What time zone baseline for insert into the db should I use?
Thanks in advance for your help!
PS My application is primarily looking at 'smalldatetime' data - down to the 'minute' level.
 
 

View 6 Replies View Related

Best Practice For Add, Edit Records Into Database With Lots Of Fields ?

Feb 7, 2006

What's the best practice for adding / editing a record into a database with lots of fields ?I am not talking about the mechanics of it, as there are a lot of trivial examples using ADO.NET, stored procs, etc.
Deleting is easy, you just pass in (a few) primary key/keys to uniquely identify the record.
But in the real world when you have, say, a table with 100 fields! Do you code the INSERT sproc by hand,  with 100 parameters... then call it with your ADO.NET code ? sounds like a lot of work to me...
What about updating! That's even worst, sometimes you may need to update only 3 or 4 fields, but using sprocs you would have to pass the whole 100 parameters in again, and "update" the whole record (when in fact you are only changing 3 or 4 fields).
With the update i could write different sprocs targeting only the fields i wish to update, but that sounds like duplicating work, vs having one generic update proc.
Sometimes i just feel like bypassing sprocs and having inline sql as it would be less work... but i know it is untidy.. and more potential to be buggy.
So come on guys (and gals)... let's hear your thoughts on how you would handle the insert  / update scenarios when you have lots of fields ? Northwind examples are too trivial :-)
 

View 1 Replies View Related

I Have Got Dts Working In Express

Mar 20, 2007

I have DTS woking with the full features as in enterprise within SQL express. :)

View 2 Replies View Related

I Have Only Started Working With SQL Express

Nov 27, 2007

And now i'm looking for what in SQL Server 2000 used to be:
Management->
SQL Server Agent->
jobs Can anyone help me find where i can add a job in SQL Express please?
Thanks

View 2 Replies View Related

Working With Sql Server Express

Mar 7, 2008

How can I devise best further to my query's and tables (without my users must stop with these data to consult)?

View 12 Replies View Related

How To Get SQL Express Working Remotely?

Sep 27, 2006

Hello all,



I am having trouble getting SQL Express 2005 on Windows Server 2003
working remotely. I have set it up for TCP connections and all,
and I can connect to the server fine, but I am unable to login. How do
I go about creating accounts for the db that will allow me to access it
remotely?

View 1 Replies View Related

Download Link Of SQL Express 2005 Not Working

Feb 12, 2007

When I click Download, it show NOT FOUND

What happened ?

View 1 Replies View Related

SQL Server Express Advanced Reporting Services - Not Working

Nov 26, 2006

I installed the SQL Server Express Advances w/ Reporting Services, but it doesn't appear to be working. When I bring the URL up in my web browser all I get is this:

transam/ReportServer$SQLExpress - /





Microsoft SQL Server Reporting Services Version 9.00.2047.00



Any tips on where to begin looking for what is wrong?

Robert

View 1 Replies View Related

Unable To Start Working On SQLserver Express 2005

Feb 2, 2008

I'm having a 3.0 GHz machine with 512MB Ram. however when i tried to run sql server 2005. this is the result of the System Configuration Check

- WMI Service Requirement (Success)
Messages
* WMI Service Requirement

* Check Passed

- MSXML Requirement (Success)
Messages
* MSXML Requirement

* Check Passed

- Operating System Minimum Level Requirement (Success)
Messages
* Operating System Minimum Level Requirement

* Check Passed

- Operating System Service Pack Level Requirement. (Success)
Messages
* Operating System Service Pack Level Requirement.

* Check Passed

- SQL Server Edition Operating System Compatibility (Warning)
Messages
* SQL Server Edition Operating System Compatibility

* Some components of this edition of SQL Server are not supported on this operating system. For details, see 'Hardware and Software Requirements for Installing SQL Server 2005' in Microsoft SQL Server Books Online.

- Minimum Hardware Requirement (Warning)
Messages
* Minimum Hardware Requirement

* The current system does not meet the minimum hardware requirements for this SQL Server release. For detailed hardware and software requirements, see the readme file or SQL Server Books Online.

- IIS Feature Requirement (Warning)
Messages
* IIS Feature Requirement

* Microsoft Internet Information Services (IIS) is either not installed or is disabled. IIS is required by some SQL Server features. Without IIS, some SQL Server features will not be available for installation. To install all SQL Server features, install IIS from Add or Remove Programs in Control Panel or enable the IIS service through the Control Panel if it is already installed, and then run SQL Server Setup again. For a list of features that depend on IIS, see Features Supported by Editions of SQL Server in Books Online.

- Pending Reboot Requirement (Success)
Messages
* Pending Reboot Requirement

* Check Passed

- Performance Monitor Counter Requirement (Success)
Messages
* Performance Monitor Counter Requirement

* Check Passed

- Default Installation Path Permission Requirement (Success)
Messages
* Default Installation Path Permission Requirement

* Check Passed

- Internet Explorer Requirement (Success)
Messages
* Internet Explorer Requirement

* Check Passed

- COM Plus Catalog Requirement (Success)
Messages
* COM Plus Catalog Requirement

* Check Passed

- ASP.Net Version Registration Requirement (Success)
Messages
* ASP.Net Version Registration Requirement

* Check Passed

- Minimum MDAC Version Requirement (Success)
Messages
* Minimum MDAC Version Requirement

* Check Passed

furthermore i get error 26 when trying to create new sql server database. and while doing the SQL server surface area configuration i got this message.:

SQL Server 2005 components were found on the specified computer. Either no components are installed, or you are not an administrator on this computer. (SQLSAC)
------------------------------
Program Location:
at Microsoft.SqlSac.MainPanel.FormFeatures..ctor(String machineName, Form callingForm)

HOpefully somebody out there will help me...or is this problem only appearing in sql server 2005 and would it be a better decision to install SQL server 2000...or if someone can help me rectify this problem i'll be really thankful.

View 4 Replies View Related

Database Mirroring Monitor Not Working For One Database

Apr 2, 2008

I set up a new mirror server. Everything is good except that the Database Mirroring Monitor is not working for one of the databases. In the monitor the principal data is showing up as blank

If I look at dbm_monitor_data on the principal most of the data columns (e.g. Send_queue_size) are null where as they have data for the other databases.


Both servers are SQL Server 9.0.2047 Enterprise Edition.


Any idea what might be going on here?


Thanks in advance.

View 3 Replies View Related

SQL Server Management Studio Express, Database Explorer In Visual Web Developer Express...which To Use???

Apr 16, 2007

When I downloaded/started using Visual Web Developer I was under the impression that I needed to install SQL Server Management Studio Express in order to create/manage databases, and to provide the engine to access the data.
 Since then I have found tutorials and have successfully created/used databases solely from within Visual Web Developer. I'm assuming that Visual Web Developer includes a database engine, much like the webserver that is included. (This is an awesome thing).
 When I tried to upload my web application with database to my production server, the database would not work, it started working after I installed SQL Server Management Studio Express on the server.
 Is it my understanding that you need SQL Server Management Studio Express if you do not have Visual Web Developer Express installed in order to provide the data access engine?
Also, I am unable to "attach" my Visual Web Developer Express created database to SQL Server Management Studio Express. Are there any posts that provide more information about this topic?
 
The only reason I'm asking is that I have extra whitespace on the end of my text fields, and I thought ANSI_PADDING was turned on. I do not see the option in Visual Web Developer Express, but have found it in SQL Server Management Studio Express.

View 14 Replies View Related

Database Connection: Mapped Network Drive (VC++ Express, MSSQL SMS Express, XP)

Sep 8, 2007


Hi


I have VC++ express and MSSQL SMS express and have an application working nicely locally. The Data explorer and data connections part works really easily.

Now, I want to make the application available to my home network.

I mapped the drive where the database is and called it Z: so I could put my "release" on my other network PC and assumed it would find Z: if I mapped the shared network drive on that machine and called it Z:

But: I can't even add the mapped connection on the local machine, I get:

The file "Z:databasescalorie.mdf" is on a network path not supported for database files. An attempt to attach.....etc"

It works fine on the original F drive.......

Am I approaching this the wrong way. How should I distribute to network PCs?

thanks hopefully
David

View 5 Replies View Related

Import Existing Database Into SQL SERVER EXPRESS Management Studio Express

Feb 18, 2008



Hi,

I am a newbie so i apologies beforehand for any mistakes i make on this forum.
Anyway, i created an asp.net website using the MS Visual Web developer tool. This has a couple of SQL SERVER databases within it.
I then latervinstalled the SQL SERVER management studio express in order to manage the SQL SERVER DBs that i had as part of my website but they do not appear within the management studio db list.
As this is the express version, is there anyway of importing the existing SQL SERVER dbs that i have to the management studio so i can manage them from there?

Regards,

Shuja.

View 5 Replies View Related

Error Creating First SQL Express Database Via VWD 2005 Express: User Does Not Have Permission To Perform This Action

Aug 18, 2006

I get an error dialog when I try to create a new SQL database, both via the Add New Item dialog and the property wizard of a new SqlDataSource control. The error is:


Local Database File:

User does not have permission to perform this action.

I've searched for help with this.

I ensured the App_Data folder exists and I added the local ASP.NET account to the group that have R/W access to it (although the RO flag is in an unchangeable tri-state on the folder).
The SQL Server Express error log is clean and indicates full functionality.
Everything is running locally.
No VWD installation errors.

Any ideas?

Thank you!

View 3 Replies View Related

Working With DataBase

Oct 12, 2007

 In my Database, there is a Table name Quote which has a column name Quotation. Quotation has some Quote inserted into it.In my web form, there is a Search button with a text box named SearchTextBox. When I enter a word on that text box and click on the Search Button, my resulted page gonna be only those rows from Quote Table which match that word. How can I do it?Hints: Select * from Quote where Quotation like '?????'    

View 2 Replies View Related

Problem Connecting To Sql Express Database From Visual Web Developer Express

Apr 7, 2006

Here is the error message I get:http://img109.imageshack.us/my.php?image=error2ug.jpgI have just installed both packages and havent done much in the way of configuration...  What do i need to do?  Thanks!

View 2 Replies View Related

Deploying Multi-user Sql Express Database To SQL Express Server

Jul 10, 2007



Okay, I've read massive topics on ClickOnce, and embedded database applications, etc, etc.



I need a handful of good suggestions how I can create a deployment package, to get my sql express database onto a SQL Express server.



The database will need to be multi-user, because I am also developing a WinForms application to connect to the SQL Express database.



I'm thinking I need to use some automated scripting features, to generate scripts for the database once I am done (unless you have a better suggestion).



After that, I need to know what to do with those scripts, and how can I create a setup / deployment packages to run those scripts against a SQL Express server.



The other alterntative obviously is to copy my sql express database, and run an attach command. This will work the first time, only because this will have been the first deployment of this database.



Please keep in mind when answering this question, that I will not be embedding the database, and as far as I understand ClickOnce is a feature for use with embedded databases or user instance databases (not sure).



Daniel Crane

View 6 Replies View Related

Why Can't I See My Web Developer Express Database From SQL Server Management Studio Express?

Apr 30, 2006

Hi, I'm completely new to SQL Server and ASP.NET, so please bear with me on my learning curve! I've installed Visual Web Developer Express and SQL Server Express (on the same PC). I then used Web Developer Express to successfully create a new database with a couple of tables in it. So far so good. I then installed SQL Server Management Studio Express on the same PC and tried to connect to my new database. The connection to the SQL Server instance appears to work OK (using Windows Authentication) but I can't see the database I previously created. All I can see are the System Databases. Does anyone know what the solution might be?

View 4 Replies View Related

Northwind Database In SQL Server Management Studio Express Is Lost Or Used/processed By VB 2005 Express:How To Locate/return It

Dec 3, 2007

Hi all,

In the last one and half years, I used the Northwind Database in SQL Server Management Studio Express (SSMSE) to learn the programming of SqlConnections, Data sources, Database Exploere, ADO.NET 2.0, etc. via VB 2005 Express.

The Northwind Database in my SSMSE got lost very often, but I was not aware of it. How can I know where the Northwind Database is used or processed by my VB 2005 Express projects that were the examples of some tutorial books or my trial projects? How can I release the Northwind Database back to my SSMSE from the VB 2005 Express projects? Please help and advise.

Thanks in advance,
Scott Chang

View 2 Replies View Related

Loading Images In A SQL Server Express Database Table At Design Time Using Visual Basic Net Express Editon

Jun 24, 2007

I am new to this type of programming and and have read all articles on adding an image to the database and it seems they all use sql queries to add an image but I want to add an image at design time. I am using Visual Basic 2005. I am also using Visual Basic 2005 Express Edition to try the same thing. I am trying to build a Translator program for english to Brazilian Portuguese and the reason I want to add the images is so that when I translate the word cat from english to Portuguese, I can also show an image of a cat. Can anyone please help me

View 3 Replies View Related

Database Mail Not Working

Jun 26, 2007

Hi
I have set up database mail.
I know the settings are correct because I use the same ones for MS Outlook on the same machine.
I am getting the following error.
-----------------------------------
The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 6 (2007-06-26T06:25:01). Exception Message: Could not connect to mail server. (No such host is known). )
------------------------------------
Service broker is enabled.
Database mail is started.

i really don't know what else it could be.
...Does SQL Server Agent have anything to do with Database mail?
Any other suggestions gratefully accepted..
ICW

View 8 Replies View Related

Working With The Old Database For The New Site?

Sep 28, 2007

I have contracted a webproject to be done. My client allready has a website. I need to create another website that replace the existing one with the new look.
This is the problem. The old website has a Database that is associated with user registration & all other data of the company. So, I need to implement the same database to the new website which I am going to develop.

In this case, how can I start? can I add a SQL express databse to the new project and import the data while the development phase? or should I use a SQL server installed while developing the site?

Please give me an easy to understanable reply that I can deal with the old database?

View 6 Replies View Related

VB Express Connecting To Remote SQL 2005 Express Database?

Nov 26, 2007

Can VB 2005 express able to connect remote SQL 2005 express database?
I played with connection string many time and still could not success!
 Thanks all.
 

View 1 Replies View Related

Backup Database Over Network Not Working.

Mar 16, 2004

The database server is on computer P4.
Computer P3 has a shared folder with full access.
Computer P5 on which I have my Backup Device and will execute the Backup Database Command using Query Analyzer.

On P5 I created the Backup Device:

USE master
EXEC sp_addumpdevice 'disk', 'myDevice',
'\P3 emp est.bak'

Then I executed the following on P5 Query Analyzer:

Backup Database myDatabase TO myDevice


But I get this error:

Server: Msg 3201, Level 16, State 1, Line 1
Cannot open backup device 'myDevice'. Device error or device off-line. See the SQL Server error log for more details.
Server: Msg 3013, Level 16, State 1, Line 1
BACKUP DATABASE is terminating abnormally.


Any idea? Thanks and regards.

View 4 Replies View Related







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