Script Database (schema And Data) And Run This Script During Web Setup Installer

Nov 26, 2007

I have created a Web Setup Project for my web application which also contains a database. Currently I am having troubles scripting the database and run it during my Custom Action for the setup project.

I used the publishing wizard to create a sql script that contains both the schema and the data for the database. However when I run the script using





Code Block
SqlCommannd.ExecuteNonQuery();


it fails. I believe this is because the ExecuteNonQuery method does support SQL statements like GO etc that are part of the SQL Script. So I now believe my approach is wrong. So my question is how should I script my database (both schema and data) and run this script during the Custom Action of my setup?

View 3 Replies


ADVERTISEMENT

Not Allowing Setup. Getting Error Trying To Run Windows Cleanup Installer

Feb 4, 2008



I cannot go backward or forward on installing SQL Server 2005. Do not have programs installed, but setup disk claims it is already installed.
Tried running Windows installer CleanUp and got the following error message when trying to install
Run Time error -2147024882
System Error &H80004005

Thanks!
Terry

View 1 Replies View Related

How To Export Whole Database Schema To Another Database But Not Include The Data?

Sep 21, 2007


I need to export a database, x, of a server, X, to another database, y, of a server, Y and I need export the database schema only, not include the data.
Does anyone know how to do that?
Many thanks for replying.

View 7 Replies View Related

How To Setup A Many-to-many Schema To Favor Retreival Speed.

Oct 30, 2006

I'm am novice in the RDMS world. I would like to set up a database that will scale with a large dataset of over 1,000,000 unique records. In a nutshell, I have about a million+ documents that are stored on a file server as TIFF files. Each document has 2 or more persons (names) associated with that document like "John Smith" or "Mr. John Doe" etc.. A person can be related to many documents (depending on how many transactions they conducted over the years) and any document can be related to many people as most of the transactions were from multiple sellers and multiple buyers. The end users almost always searches for documents by using the first and last name of the person related to the document along with other document fields such as DATE and TYPE to narrow the search. I would like to design and index the database for fast searching as updates are not as time sensitive. I think I need at least 3 tables:

1) NAME_TABLE normalized into NameID(PK) NameFirst, NameMiddle and NameLast

2) DOC_TABLE normalized into DocID(PK), DocTransNum, DocFilePath, DocDate, DocType, (and other attributes)

3) NAME_DOC table to relate the above two tables in a many to many relationship.

My questions are: Where should I put the field that identifies the person as a buyer or seller as it relates to the document? John Smith can be both a buyer and seller on different documents so I don't think it belongs in the NAME table. If I have a another table that splits the names into SELLER_NAMES and BUYER_NAMES it would create some duplicate names and increase the search time right? I want to search for a document using a name and the option to specify if the person name search is limited to buyers, sellers or both. Do I need to do anything special in setting up the tables for fast searching other than indexing all the name fields and the DocID field? What indexing needs to be done on the many-to-many table if any? If fast searching on a mostly static database is a top requirement, should I denormalize the document table to include the names even though there will be duplicate names throughout? How large of a test set of records do I need to load to see any real deltas in performance as I modify and tweak?

Sorry for all the questions but I believe they are related to the overall problem to solve.

Regards,

DeBug

View 10 Replies View Related

The 'System.Web.Security.SqlMembershipProvider' Requires A Database Schema Compatible With Schema Version '1'.

Sep 27, 2007

Locally I develop in SQL server 2005 enterprise. Recently I recreated my db on the server of my hosting company (in sql server 2005 express).I basically recreated the tables and copied the data in it.I now receive the following error when I hit the DB:The 'System.Web.Security.SqlMembershipProvider' requires a
database schema compatible with schema version '1'.  However, the
current database schema is not compatible with this version.  You may
need to either install a compatible schema with aspnet_regsql.exe
(available in the framework installation directory), or upgrade the
provider to a newer version.I heard something about running aspnet_regsql.exe, but I dont have that access to the DB. Also I dont know if this command does anything more than creating the membership tables and filling it with some default data...Any other solutions/thought on what this can be?Thanks!

View 4 Replies View Related

Protecting Database From Code Stealing And Installer Advice

Aug 24, 2005

Dear GroupI'd be grateful if you can give me some advice on the following.An application I wrote uses an MSDE backend and I wonder whetherthere's a way (even for the system administrator) of not seeing ortracing stored procedure code, view and table designs?And I also wonder whether you can advise me on an installer thathandles MSDE and database setup during installation without too mucheffort but is still affordable < USD 1000.Any articles, resources, advice hints for these two topics are veryappreciated.Thank you very much for your help & efforts!Martin

View 3 Replies View Related

How To Setup Replicating Data To Oracle Database

Jan 30, 2006

How do you setup replication from SQL Server 2000 to a oracle database? We want to push changes from sql sever to oracle, evertime sql server table is changed. I have a working ODBC connection. When I try setting up a push to the oracle side I can not find the subscriber In the list. Can someone point me in a direction, with a detailed way of doing this.

View 1 Replies View Related

Database Schema Compatible With Schema Version '1'

Apr 12, 2008

Hello everybody!I'm using ASP.NET  3.5,  MSSQL 2005I  bought virtual web hosting .On new user registrations i have an error =(The 'System.Web.Security.SqlMembershipProvider' requires a database schema compatible with schema version '1'.  However, the current database schema is not compatible with this version.  You may need to either install a compatible schema with aspnet_regsql.exe (available in the framework installation directory), or upgrade the provider to a newer version. On my virtual machine it work fine but on web hosting i have an error =(What can you propose to me?

View 2 Replies View Related

Moving Data From One DB Schema To Another DB Schema Using SSIS

May 8, 2007

Hello,



I would like to use SSIS tool to move the data from one database schema to another database schema.



For example:



Source table has

1. UserName (varchar 20) (no null)

2. Email (varchar 50) (can be null)



Destination table has



1. UserID (uniqueidentifier - GUID)

2. UserName (varchar 50) (no null)

3. EmailAddress (nvarchar 50) (can be null)

4. DateTime



Questions:



1. What controls do I use in my Data Flow to make data move between databases with different data types and include new value in UserID as a new GUID and DateTime as a date (GETDATE)?

OLE DB Source, OLE DB Destination, Data Converson and .....

How do I insert Guid and Date at the same time?





2. I have many tables to do data moving. Any sugestions? How do I architect my project? If I create many data flows for each table - it will look complicated.



Please give me some advices here.



Thanks.

View 3 Replies View Related

SQL Server Admin 2014 :: Setup Database Part Of Data Center?

Apr 8, 2015

My company is migrating all their servers to a new data center and I get to specify what we need for the db servers.

We've got a 22 prod servers (mainly physical) with a couple of TB of data on sql 2000 to 2012.

We expect to move to sql2014, and consolidate and virtualise where ever possible.

But I'd like start with specifying an overall architecture for this: some Best Practices to guide the build at a server and an installation level

View 1 Replies View Related

A Way To Do The Execute Script And Script The Schema AND The Data (run It On An Empty Database And Autocreate)?

Apr 21, 2008

I'm trying to find out if this is possible.. i know that you can do an execute script command and have it export the results to a script file or clipboard.. then in a new database, run that in the query window and it will recreate the table schema.. but is there a way to do the entire table, contents and all via a script in a similar fashion?

This would be with SQL 2005 standard edition...

Thanks for any input.

View 1 Replies View Related

SQL Server 2005 Express: The Database Principal Owns A Schema In The Database, And Can Not Be Dropped.

Jan 11, 2006

I recently added a new user to my database.  Now I want to delete that user, but I keep getting the error above.  What do I need to do to delete my recently added user?

View 4 Replies View Related

SELECT Permission Denied On Object 'TableID', Database 'Database', Schema 'dbo'

Mar 21, 2007


The error message:

An error has occurred during report processing. (rsProcessingAborted)
Query execution failed for data set 'TestID'. (rsErrorExecutingCommand)
For more information about this error navigate to the report server on the local server machine, or enable remote errors

The log file reads:

---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Query execution failed for data set 'TestID'. ---> System.Data.SqlClient.SqlException: SELECT permission denied on object 'TableID', database 'Database', schema 'dbo'.

***Background***

General Users got an error message when trying to access any reports we have created.
All admin have no problems with the reports. Users (Domain Users) are given rights (Browser) to the reports and the Data Sources (Browser) and yet cannot view the reports.

An error has occurred during report processing. (rsProcessingAborted)
Cannot create a connection to data source 'DS2'. (rsErrorOpeningConnection)
For more information about this error navigate to the report server on the local server machine, or enable remote errors


I'll add this from the report logs...

w3wp!processing!1!3/20/2007-11:43:25:: e ERROR: Data source €˜DS2€™: An error has occurred. Details: Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Cannot create a connection to data source €˜DS2€™. ---> System.Data.SqlClient.SqlException: Cannot open database €œDatabase€? requested by the login. The login failed.
Login failed for user €˜DOMAINUsername€™.

The user has rights via a local group to the report and data source (Browser rights) and the local group has been added as a SQL login.


I gave rights to the databases themselves instead of just to SQL and the error changed (Ah-ha...progress, but why!?!?)

View 3 Replies View Related

The Database Principal Owns A Schema In The Database, And Cannot Be Dropped.

Feb 15, 2006

Trying to get my hands around all the new security features of SQL Server 2005. In Management Studio did something I don't know how to undo. I added a database role ReadOnlyRole and clicked the box next to db_datareader in the owned schemas box. Then I tried to remove the ReadOnlyRole and could not. How do I undo what I did? Is it possible?

The below is the TSQL that generates the my issue.



Use [master]
go
create database [test]
go

USE [test]
GO

CREATE ROLE [ReadOnlyRole]
GO

USE [test]
GO

ALTER AUTHORIZATION ON SCHEMA::[db_datareader] TO [ReadOnlyRole]
GO

drop role [ReadOnlyRole]
go

View 12 Replies View Related

Physical Setup: 1 Data File Vs Multiple Smaller Data Files

Jul 20, 2005

Hello all. Before my arrival at my current employer, our consultantsphysically set up our MSSQL 7 server as follows:drive c: contains the mssql enginedrive d: contains the transaction logdrive e: contains the data filesNo filegroups were set up and the data files consist of only 1 largephysical file. Currently, our data file is >10GB. When I was trained onthe physical aspects of sqlserver, I was told to never create physical files[color=blue]> 2048MB each. If I did, I could expect inefficient physical storage of[/color]data and slower performance (due to the OS).Our server has 2 RAID-5 arrays. Drive c: and e: are located on the firstarray and drive d: on the second. We're running Windows 4.0 NT Server SP6with NTFS.Can someone comment on the use of 1 single large data file vs. more smallerdata files?

View 2 Replies View Related

Database Schema

Apr 28, 2005

What would be the best way to get the Schema from a complete database.

Thanks.

View 1 Replies View Related

How To Get All Database Schema?

Sep 9, 2005

hello,

here is my problem.
I have to rebuild database after crash. there is no backup. So
I did a bcp to get data from. But I do not have the original database so my question is how to get the full schema off the data base, tables,colomns,stored procedures etc...

thanks lot for any help.

View 1 Replies View Related

Help For Database Schema

Mar 16, 2007

Hello All,

My project uses MS SQL server database and is not too big database (have aound 200 table).

Now I have to create Database schema for my database as my project needs to be integrated with some other product.

I don't know much about database schema and how to start with it.

Can someone please give me some inputs on following:

1) What exactly database schema should include?

2) How should I start creating the schema for my database?

3) Are there any tools for doing this?



Thanks in advance

View 12 Replies View Related

Sql Database Schema

Oct 24, 2005

Hi. I would like to retrieve the table names of a database, the column names nad its contraints of each table in a database.. How can this be achieved???

View 14 Replies View Related

Database Vs Schema

May 24, 2007

We currently have a product in which each client has their own Database. We adjust the connection when a user for that client logs into the system. This system has continued to grow and a good pace, but we have come to a point where failover is taking too long.



Refactoring the Database to handle multiple sites in a single database is not an option because of the time it would take to make the change. So, we are looking for another way in which this could be handle. One idea is to take multiple clients and place them in a single database using a schema to seperate them. (ex. Client A = server1.db1.schema1, Client B = server1.db1.schema2, etc).



Is there another option that would be better, or what kind of performance can we expect if we follow this path? Or, is there a way to decrease the failover time (it appears the problem is the startup of the database on the failover server)?



Thad

View 4 Replies View Related

RS Database Schema?

Oct 26, 2007



We have a RS 2000 server with a over a hundred reports, and about half as many weekly and monthly subscriptions.
In reply to my request to upgrade to RS2005, the boss asked me today for a compete list of the reports, who subscribes to them, and their delivery frequency.

He was not interested in paying for a VB or C# development effort with the SOAP API that it would require to obtain a simple list from a SQL server database, since he already has SQL programmers on staff.

So how can I get this list? Anyone know of any demo code out there?

Forgive my sarcasm and Thanks in advance.

Herb

View 4 Replies View Related

Changes To Database Schema

Oct 23, 2007



Does anyone know which database table/view one can query to get a list of all objects that have been changed by users accessing a database?

Is there any? or is there some other way of doing this?

View 1 Replies View Related

Need To Get Schema And Data From 6.5 To 7.0

Jun 19, 2000

Hi,

i need to move the data and schema from 6.5 to 7.0. could you please tell me the most simple way.


thank you

raju

View 1 Replies View Related

My Installer

Mar 2, 2008

Hi everyone. I have a question.

I have an installer that runs seamlessly in any 32bit -x86 OS. But if I tried to run the exe(installer) to any 64bit OS, yeah it runs and creates a database, but does not create a tables on it...

The installer is compiled in a platform 32bit OS.

Do you have any idea about this? Do I need to recompile the application in a 64bit OS?

RON
________________________________________________________________________________________________
"I won't last a day without SQL"

View 8 Replies View Related

Exporting Database Schema

Sep 26, 2006

Is there a way for VS2005 to export the database schema of a .mdf into a .sql file? Preferably from a Web PRoject, not a Database Project, but right now I am anything but picky, so whatever works. Thanks. 

View 6 Replies View Related

SQL Database Schema Sync

Oct 15, 2007

SQL Database Schema Sync
We have development and production databases, when we change database schema in development database how can I synchronize it to production without creating data problems in production, is this possible in SQL2005? Or any external tool I can use?
 

View 1 Replies View Related

Replication Of The Schema Of A SQL Database

Nov 12, 2007

Hi all,
I am doing a replication of a SQL Server 2005 database from one server to another server, everything worked fine. Now, when I added some fields to this database, the replication stopped. can I do replication of a schema of a SQL database? how? Should the replication work even if I add some fields.

View 3 Replies View Related

Copy The Database Schema

Feb 4, 2002

Hi,

Can anyone help me to figure out how to generate the SQL Script that can produce the same database schema with the existing database?

I have tried the "Generate SQL Script" tool. However, it only creates the object such as tables, stored procedures, triggers and etc. I still have to create the database first in order to run that script. I have an existing database that has a 2.7 GB size (let's called this ABC Database). In a different server, I would like to create the same database with the ABC DB without having to restore the ABC DB. Bottom line, I would like to see the script creates the database along with all stored procedures, triggers and the size of the database will be 2.7 GB. Is it possible?


Thank you very much!
Jane

View 2 Replies View Related

Database Schema Exported......

Jul 10, 2002

MS SQL 6.5
NT

I have been asked to export the database schema (containing table names, field names, data types, field lengths, field defaults, nulls, etc) to an MS Excel spread sheet. "sp_help filename" provides some data but the format is difficult to manage.

All help with this matter would be greatly appreciated....


Thanks in advance.

View 1 Replies View Related

Database Schema Designing

Feb 26, 2004

Case 1:
A company is involved into e-commerce..hosting multiple websites for different products.

CAse 2:
The above scenario could also be implemented with a single site having multiple products for sale.

For Case 2 one would go for a single database for all the products.
While for CAse 1 ,a separate Database is developed for each Site.


What I fill is CAse2 is a more appropriate choice even if we have multiple sites for different products.

This would help us in rapid development of any ecommerce site...
ANd better ERP management for the Company.

I would appreciate some expert guidelines for the above scenario


Thanx in Advance
Warm Regards
Girija

View 1 Replies View Related

Obfuscate Database Schema

Jun 6, 2007

I can't believe I am asking this but I have been "requested" to.

Scenario:

Database based app installed on client site

Goal:

Protection of database schema.

Solution:

Obfuscate? - Any tools available?
Host db in secure location - Not going to happen!


Any thoughts?

DavidM

Production is just another testing cycle

View 11 Replies View Related

Copying The Database Schema

Aug 2, 2007

Hi Friends

We have a database that contains tables having 4 million records
Can you tell me a way to copy the schema of the Database to a new database.

Generate SQL Script...Is it the only option or can i use the DTS package

Which is the most reliable one?

Regards
Vivek

Vic

http://vicdba.blogspot.com

View 1 Replies View Related

Database Schema Conversion

Jul 20, 2005

Hello all,I am doing some research on database conversions. Currently, I aminterested in any information that would help me convert a database fromone schema to another. This could be changes as minimal as adding afield to a table, or as large as deleting tables and changingrelationships. Unfortunately, my experience with SQL Server is minimal.I know how to do a lot, but I do not know a lot of intricacies thatmost experts know. I know how to add tables, delete them, alterrelationships, add fields, work with stored procedures, take care ofsecurity, etc. I also know how to backup, restore, etc.The type of information I am looking for could be:1) Open source software that performs conversions2) Tutorials/books/<any reference> that would assist me in learningwhat I must to complete this task.3) Third party software that could be used on a large scale andwouldn't resort in unnecessary licensing cost if I was to deploy on thislarge scale.I greatly appreciate any information that could be provided me.To give you guys an idea of my experience level:I've been programming C# and .NET for a year now. I've also hadextensive experience in object-oriented design. I've worked with visualbasic, cobol (did I mention this? LOL), asp.net, php, javascript, andseveral other programming languages on an extensive basis. Whileprogramming is my speciality, I've strayed away from database work untilnow. I would greatly appreciate any assistance in researching this matter.Thanks ahead guys,Shock

View 5 Replies View Related







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