Sql Server Express Problem When Moving From VWD File Based To IIS

Dec 5, 2006

Hi All,
 
We have a file based asp.net app built using Visual Web Developer and Sql Server Express 2005. We have finished development and testing and are now moving to the deployment stage. As a first step, we would like to be able to view it on a test machine using IIS (instead of VWDs built in web server). We have created a virtual directory in IIS and can view our app correctly at http:localhost/ForIIS_test.
 
However, when we get to a page that tries to access our Sql Sever Express database, we get the following error:
An attempt to attach an auto-named database for file C:Documents and SettingsClaudeMy DocumentsVisual Studio 2005WebSitesForIIS_testApp_Data estDatastore.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.

Does anyone know how to overcome this problem? Any help appreciated.

Claude.

View 1 Replies


ADVERTISEMENT

Remote Connection To File-based Express DB

Mar 25, 2006

Hi,

This might be obvious - but if so I've missed it so far.

Is it possible to connect remotely to an Express database used in a website which is created in the App_Data folder by VWDEE 2005 and attached by filename?

As far as I can tell these databases don't have a name and aren't mounted until an attempt is made to access them. I certainly can't see any sign of it in SQL Management Studio.

Thanks,

Dale

View 3 Replies View Related

Moving From SQL Server Express

May 15, 2007

Hello,



I was wondering if it was possible to move a database from the Express edition of SQL Server 05 to say an enterprise edition without having to make major updates or changes to the database.



Thanks in advanced.

View 3 Replies View Related

Moving From SQL SERVER Express Edition

Apr 21, 2007

I have installed the Classifieds Starter Kit and have imported the ClassifiedsDB from Express to SQL Server running on a remote machine.
I have edited the classifiedsceonnection string in the Web.Config to point to the db. However, the
AspNetSqlMembershipProvider is still looking for the LocalSQLProvider, I changed that to poing to the same classifiedsconnectionstring and it errors;
I will post error here:
SQLExpress database file auto-creation error:
The connection string specifies a local Sql Server Express instance using a database location within the applications App_Data directory. The provider attempted to automatically create the application services database because the provider determined that the database does not exist. The following configuration requirements are necessary to successfully check for existence of the application services database and automatically create the application services database:

If the applications App_Data directory does not already exist, the web server account must have read and write access to the applications directory. This is necessary because the web server account will automatically create the App_Data directory if it does not already exist.
If the applications App_Data directory already exists, the web server account only requires read and write access to the applications App_Data directory. This is necessary because the web server account will attempt to verify that the Sql Server Express database already exists within the applications App_Data directory. Revoking read access on the App_Data directory from the web server account will prevent the provider from correctly determining if the Sql Server Express database already exists. This will cause an error when the provider attempts to create a duplicate of an already existing database. Write access is required because the web server accounts credentials are used when creating the new database.
Sql Server Express must be installed on the machine.
The process identity for the web server account must have a local user profile. See the readme document for details on how to create a local user profile for both machine and domain accounts.
Any suggestion of how to resolve this to look at the SQL Server on remote machine?

View 1 Replies View Related

Moving Data From Excel To SQL Server 2005 Express

Oct 17, 2006

I am trying to load data from an Excel spreadsheet file into SQL Server 2005 Express. I understand that DTS is the best tool for doing this but from my research it appears that DTS is not available with the Express edition and the import wizard that does come with Express is not well suited for this type of conversion.

Does anyone have any suggestions for how to achieve this objective? Thanks for any help you can provide.

View 7 Replies View Related

Moving A Database Application To SQL Server 2005 Express

Sep 13, 2006

I have been programming an application with VC++ 2005 and SQL Server 2005. I have converted an old 16-bit database to 32-bit managed code and SQL server and the application seems to be good. Now I want to deploy the application to another server for testing.

I have installed XP SP2, Windows Installer 3.1, Net framework 2.0 and SQL Server 2005 express to the test server. I have transferred the application with WI 3.1 and the program works well in the test server till the first SQL command. I have made a back up of the database and restored it in the test server. In the test server I can log in the database with Server Management studio and I can read the data there correctly. I have enabled both named pipes and TCP/IP for the database in the test server. With Surface Area Configuration I have enabled Local and Remote Connections Using both TCP/IP and named pipes. I only need Windows authentication at this time.

After all this when I come to the first SQL command in the application on the test server I receive the error message:
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: Named Pipes Provider, error: 40 €“ Could not open a connection to SQL Server).

My connection string to the database is:
'connection->ConnectionString = "Persist Security Info=False; Integrated Security =SSPI;"
"Data Source=TESTSERVER; Initial Catalog=TESTDATABASE;";'

When I use "Data Source=DevelopmentServer", the application works well on the development server.

Can't understand what is still wrong. Can you possibly have an answer for me?

View 4 Replies View Related

Moving Transaction Log File In SQL Server V7

Mar 2, 1999

I'm in the process of tuning a SQL Server v7 box and have decided that the transaction log would be better placed on its own disk. How do I move a transaction log ?

View 1 Replies View Related

Moving A Text File To Sql Server

Feb 17, 2008

I have a text file and moved the data to sql server using import and export data. These are step I am doing.

1. Open Microsoft Sql Server and select DTS Import Export Wizard
2. Using the wizard , I am selecting the Data Source as Text File and provided the file name.
3. In the next option, I am choosing Delimited , followed by Tab option.

4. Then, I am selecting the required Destination and the required Database also.
5. I am choosing the files specified and Run the file.

This method works perfectly.

However, I want a method, where I could avoid steps 1 thru 5 and provide the user a singe step. I mean just an execute of a stored procedure should do the steps 1 thru 5. Is that possible.

Thanks.

View 8 Replies View Related

Moving Tables/Procedures From SQL Server Express To SQL Server

Mar 31, 2008

My searches have come up blank, so I'm hoping someone else can point me in the right direction.
I'm done some development in SQL Server Express, working on tables and procedures.  I've now got to move those tables/procedures into SQL Server and I don't know of an easy way to do this.  Are there any tools I can take advantage of that would allow me to get all these objects moved?  The only way I can see to do it is to move objects over one-by-one.  This would be really time-consuming, and I'd like to avoid it if possible.
I'm positive I'm not the first one to try this, but what should I be searching for?  Are there tools/procedures I should be looking for?
Appreciate any help I can get.
Thanks.

View 2 Replies View Related

Help Moving From SQL Server Express To SQL Server Developer

Jan 24, 2007

I built a web application using my VS2005 installation, which includes SQL Server Express.
All works nicely.  However, when I tried to move this application to a system with SQL Server Developer, I cannot get it to work at all - data access receives several errors, with the most common being this one:
Cannot open database "xyz.mdf" requested by the login.  The login failed.  Login failed for user 'MACHINEASPNET'.
Here is my connection string (with specific names changed, obviously):
Data source=MACHINE;Initial Catalog=xyz.mdf;Integrated Security=SSPI;User=Me;Password=MyPassword
I have given users MACHINEASPNET and MACHINEMe all possible permissions (that I know) within SQL Server.
I have spent days on this, with no solution - help would be most appreciated.
 

View 3 Replies View Related

SQL Server 2008 :: Moving Tables To New File Group

Mar 16, 2015

I'm presented with an issue where by I need to reclaim a fair bit of unused space currently sat in the primary data file for my database. I don't want to run DBCC SHRINKDATABASE as we all know this could potentially have a some serious negative effects relating to index fragmentation.

So, how do I get the free space out of the data file? - I've decided to:

1. Add new new file group
2. Add a clustered index for all tables on the new file group
3. Shrink the primary file group as much as possible (hopefully giving me the free space back)
4. Drop the newly created clustered indexes for all tables

There are no clustered indexes currently for any of the tables!, so me temporarily creating/dropping one shouldn't be an issue. Are there any other ways I can get the free space back to the OS?

View 8 Replies View Related

Moving From Access To A Web Based Approach

Aug 7, 2006

Hi all.

I am not a programer but managed to piece together an Access database that is the backbone of my company.

My IT group advised me to move to an SQL server back end and move to a web based front end.

My question. I am very comfortible with Access and modify the databases regularly. What front end is most like Access for modifying forms, reports, macros, etc.

Thanks!

View 2 Replies View Related

Query Data Based On Moving Datetime.

Feb 5, 2008

I'm trying to query data from a database for a report that looks for the last 2 weeks starting at 10pm, taking a value once every 24 hours. Using

AND DateTime >= DateAdd(wk,-2,GETDATE())

AND DateTime <= GetDate()")
I easily get the last two weeks but the query obviously only grabs the data at the time the query runs. I need to be able to run it any time of the day but only grab the data at 10pm. I'm very new at this so please excuse my ignorance but I could really use some help with this. Thanks very much.

View 4 Replies View Related

Moving Average Using Select Statement Or Cursor Based?

Jul 30, 2007

ID DATE(dd/mm/yy) TYPE QTYIN COST_IN_AMT COST_OUT_AMT(MOVING AVERAGE)
1 01/01/2007 PURCHASE 10 1000
2 01/01/2007 PURCHAES 5 1100
3 01/01/2007 SALES -5 *TobeCalculated
4 02/01/2007 Purchase 20 9000
5 02/01/2007 SALES -10 *TobeCalculated
5 02/01/2007 purchase 50 8000
6 03/01/2007 Sales -10 *TobeCalculate
7 01/01/2007 Purchase 20 12000

I have a table when user add new sales or puchase will be added to this table ITEM_TXNS. The above date is part of the table for a ProductID . (The field is removed here)
In order to calculate the balance amount using moving average, I must calculated the cost_out_amt first on the fly.
When user add new sales I also need to determine the cost/unit for a product id using moving average. The problem is I can not just use sum, because i need to determine cost_out_amt for each sales first which will be calculated on the fly.
The reason i dont store the cost_out_amt (instead calculate on the fly) because User could Edit the previous sales/purchase txn or Insert new sales for a previous date. Example THe record with ID 9. By Adding this txn with ID 9, would cause all the cost_out_amt will be incorrect (Using moving Average) if i store the cost_amout_out on entrying txn and need to be recalculated.
Instead I just want to calculate on the fly and able to determine the cost avr for a specific point of time.
Should I just use Cursor and loop all the record and calculate the cost or maybe I can just use on Select Statement?

View 20 Replies View Related

T-SQL (SS2K8) :: Grouping Of Data Based On Moving Time Period

Mar 13, 2014

To give you some context we have a new amendments application (nothing fancy, excel based with SQL Server back end) that allows users to submit amendments to product data (Product Info, PO Prices, Dates etc.). There is also an admin tool that a team uses to action these amendments in the various systems.

The old version of this tool, users submitted amendments by style and could if need be submit multiple amendments against one product at the same time. The new tool, I believe for audit reasons, users submit by amendment type, so for example I would submit a cost price change for a given style.

The issue now is that on the occasions where a user has multiple amendments, they now come through separately. So cost price would be Amendment 1 and a date change would be amendment 2 even though they could be the same product. This could potentially mean that the admin team would be duplicating work if the paperwork is updated and sent after each amendment, whereas before they would make both changes and only send the paperwork once.

Having not built either of these tools, I've been tasked with trying to fix this, my two thoughts being either to amend the user form to somehow capture/ allow users to submit amendments together or try to use the existing data and doing the grouping dynamically in the back end. Use that lag to look at grouping any submitted amendments that occur within 30mins of the first occurrence of that style

This grouping would then be given a joint time so when the 'time lag' period passes the amendments will be visible together.I've tried a few things and a few head on desk moments trying to get a set based approach but haven't been able to get where i want, its either an issue where amendments span an hour, such as 9:59 and then 10:03 or grouping together amendments that happen after the 30mins of the first one.

Here is some sample data

USE FF_Winning_Together;
IF OBJECT_ID(N'tempdb..#AmendTest',N'U') IS NOT NULL
DROP TABLE #AmendTest;
CREATE TABLE #AmendTest
(
AmendmentIDINT IDENTITY(1,1)NOT NULL,
StyleCHAR(1)NOT NULL,
AmendmentStatusVARCHAR(10)NOT NULL,
DTDATETIMENOT NULL

[code]....

View 7 Replies View Related

An Error When Instantiating C#-based COM Object In OLE DB Provider Linked To SQL Server Express

Aug 24, 2007

Hi,


I'm working on an OLE DB provider. This provider is supposed to retrieve data from managed application running in background. The data retrieval is handled by C# component communicating with source application via remoting, the data are then exposed via component's COM interface. OLE DB provider itself instantiates the communication component.

Now, the problem: this worked ok in SQL server 2000, but it doesn't seem to work in SQL server express edition. Concretely, the communication component fails to get created (CoCreateInstance ends with 'class not registered') and SQL server logs this:


2007-08-24 14:48:49.42 spid51 Error: 6511, Severity: 16, State: 20.
2007-08-24 14:48:49.42 spid51 Failed to initialize the Common Language Runtime (CLR) v2.0.50727 with HRESULT 0x80131022. You may fix the problem and try again later.


I've googled a bit and found out someone else getting this message, and he was told something like 'trying to load CLR in some cases is disabled in newer (>2000) versions of SQL server'.

Now, I have very little knowledge of SQL server, CLR integration etc., so I'm not sure whether this applies to my case as well, but I think so - that problematic COM object is C#-based.

I'd be glad for any hints, ideas how to solve this issue, I just need the OLE DB provider to be able to access that managed application.


Thanks,L.

View 1 Replies View Related

How To Convert SLQ Server Express Database File To SQL Compact Edition File?

May 29, 2007

Hi all,



I have a database name MyDatabase (SQL Server Express Dabase File). Is there anyway that I could convert it to SQL Server Compact Edition File?



By the way does anyone here got any problem with programming in SQL Server Compact Edition? It troubles me.



Thanks,

bombie

View 6 Replies View Related

SQL Server 2008 :: Code To Generate XML File Based In XSD

Aug 2, 2015

I have data in Sql table , I want to convert it to xml using xsd using script component in ssis.

View 0 Replies View Related

How To Open .bak File Using VWD Express And SQL Server Express

Sep 8, 2007

Hi, I was sent a .bak file which I need to open and place in sql server express. I googled this but did not come up with any clear instructions. Can some please give me a good link that explains this. Thanks  

View 1 Replies View Related

Management Studio Express &&amp; SQLcmd: Syntax Errors In Executing A MS-DOS Batch File &&amp; A Microsoft SQL Server Query File?

Nov 2, 2007

Hi all,
I have the "Northwind" database in my Sql Server Management Studio Express.

In my C:ProSSEAppsSamplesForChapter02Chapter02 folder, I have the following 2 files:
(1) ListColumnValues (MS-DOS Batch File)
sqlcmd -S .sqlexpress -v DBName = "Northwind" CName = "CompanyName" TName =
"Shippers" -i c:prosseappschapter02ListListColumnVales.sql -o
c:prosseappschapter02ColumnValuesOut.rpt
(2) ListColumnValues (Microsoft SQL Server Query File)
USE $(Northwind)
GO
SELECT $(CompanyName) FROM $(Shippers)
GO
When I ran the following SQLcmd:
C:ProSSEAppsSamplesForChapter02Chapter02>ListColumnValues.bat
I got the following "ColumnValuesOut.rpt" with error messages:

'Northwind' scripting variable not defined.
Msg 102, Level 15, State 1, Server L1P2P3SQLEXPRESS, Line 1
Incorrect syntax near '$'.
'CompanyName' scripting variable not defined.
'Shippers' scripting variable not defined.
Msg 102, Level 15, State 1, Server L1P2P3SQLEXPRESS, Line 1
Incorrect syntax near 'CompanyName'.

I copied these T-SQL statements from a book and I do not know how to correct them.
Please help and tell me how to correct these errors.

Thanks in advance,
Scott Chang




View 3 Replies View Related

Update Server Table Based On Flat File Data

Feb 13, 2014

I have a table dbo.Sales that contains all sales records. There is a column in that table called ItemNumber that I'd like to match with ItemNumber in a flat file and update the ItemCost based on the ItemCost column in the flat file.

So while there will be many sales records for each ItemNumber, I need to loop through and update the ItemCost in that sales record based on the corresponding ItemCost in the flat file. Does this make sense? I really need this for court and I can't figure out how to do it. I took a SQL course about 7 years ago but have forgotten everything.

Database Name: BTData
Database Table: dbo.Sales
Database Columns: ItemNumber (match on this), ItemCost (update this)

FlatFile Name: InventoryCosts.txt
FlatFile Columns: ItemNumber, ItemCost

There will be many sales records for each ItemNumber in the database table. I need to update each one with correct cost based on the item number and cost mapping from flat file.

View 1 Replies View Related

File System Task-Moving File

Jan 19, 2008

I have the following directories

\servershare
\serversharearchvie

I have a for each file loop and inside it a data flow that pulls from one of the flat files in the directory and then a file system task. If I choose the "Move File" option in the file system task to move the file to the archive directory, it fails with an access denied message. The access denied message occurs after a message saying file was successfully deleted. I am running this from BIDS right now and my local user can write delete etc in both the above directories. However, if I do a "copy file" in the file system task it seems to work. I think what is happening is it is deleting the file first and then trying to move it, but it no longer exists because it has been deleted--is this possible? Is this a bug of some sort?

For now I am going to workaround by putting in another file system task that deletes the files after they were copied and see how that goes, but would prefer just to do the "move" option.

Thanks,
Kayda

View 3 Replies View Related

File System Task - Moving A File

Nov 7, 2006

I have a File System Task that uses variables to resolve the destination and source paths of a document. When I select the 'copyfile' operation...the document is copied from the source to the destination without error.

However when I change the property from 'copyfile' to 'movefile' I get an error and the document is not moved.

The source and destination variables contain a valid file path name since the copy commmand is working as expected. However when I alter the properties of the File System task to move the document. I get the following error:

Could not find a part of the path 'G:CommonInformation SystemsDropFilesrtNRT_ConfirmationOrder Confirmation Report_11062006.xlsOrder Confirmation Report_11062006.xls

It seems a little nonsensical since the document file paths are valid when performing a copy. For some reason the error log is showing that that the file path is the document name "Order Confirmation Report_11062006.xls" and adding it twice to the the directory path called "'G:CommonInformation SystemsDropFilesrtNRT_Confirmation" as you can see in the above error message.

To replicate the 'move' action...I added an extra File System Task that deletes the document once the copy has been performed. I would like some insight into why this doesn't seem to work.

Thank you.

...cordell...

View 1 Replies View Related

Moving Development Environment From MS SQL To SQL Express

Apr 3, 2008

Hi all

I need to move an entire live environment from MS SQL 2000 (because of developing further before uppgrading) to SQL Express but cannot get it to work. Is this possible to do at all?

/Johan

View 5 Replies View Related

Moving From SQL 7 To SQL2005 Express- Any Tips?

Dec 1, 2005

We are coming out of the dark ages with our app using SQL 7 and, following the excellent advice of the folks here on SQLTeam, installing SQL 2005 Express on our new webserver.

Not being terribly fluent in all things SQL, I was wondering if anybody could provide input on the best practices for getting SQL 2005 Express going on the new server.

So far I've:

- Installed SQL 2005 Express
- Downloaded and "installed" the SSEUtil for CMD line instructions
- Downloaded and installed the graphical management interface (very nice, makes me feel more comfortable - like SQL 7 console!)
- Copied backup files (made using SQL backup maintenance) to the new server

Should I simply create an empty db of the same name on the 2005 server and then restore the 7 data? Or ????

I searched briefly for previous posts of this nature and didn't find too much info so I hope I'm not duplicating effort here...

Thanks in advance for any advice!




Mmmmmkay. Yeah, did you get the memo about the TPS reports?

View 3 Replies View Related

Integration Services :: Move Multiple Files Based On File Names Listed In A Spreadsheet / File?

May 27, 2015

I need to move specific files from a server to another server on a monthly basis.  There are hundreds of files that are in the source directory and I need to move approximately 40 of those to the destination server.  I would like to easily add or delete the file list as needed.  I have seen where several variables were created for for each file name (and one for the path) and the ForEach Loop would go through them.  With 40 or more I was thinking that I could make a connection to an Excel spreadsheet or text file with a record for each file name and read in and and move to the next record and make that value become the content of a "FileName" variable.  Then if I wanted to add another file name I could just add another record to spreadsheet/text file or remove and the package would handle automatically....

View 10 Replies View Related

Integration Services :: Pulling File Based On File Properties

May 6, 2015

I have a task for which I have to load csv file from a shared directory into sql table. Right now I'm stuck with a road blocker, The issue is the shared drive contains all the history files as well and I have to pick only the latest file. But I cannot identify latest file based on the file name because it doesn't contain any date in the file name. However by seeing file properties I can pull latest file. 

Sample file name: XXX_XXX_XXX_XXX_XXX-5814201.csv

Is there any way we can automate this in SSIS with file properties and picking the latest one?

View 12 Replies View Related

SQL Server 2008 :: Bulk Import And Create New Table Based On Header Fields Of Imported File (XLXS)

Sep 11, 2015

I have a record in an Excel format (Excel 2010) and I would like to bulk import that into SQL Server 2008 and also while importing, SQL Server will automatically create a new table based on the header fields or row of the source file.

I am not sure if SQL Server 2008 has this capabilities.

View 0 Replies View Related

??Moving Table With Data To Another Database In Sql Express 2005??

May 30, 2006

How to move some tables with data & procedures etc from 1 database to another in sql server 2005 express edition.
i did by scripting but i transfer tables and procedures and not data
data is the problem.
tnx

View 1 Replies View Related

MOVING DATA AND LOG FILE

May 25, 2001

I am trying to move a data and log backup file from my C drive to another drive to free my C drive. Does anybody know the easiest way to do it? Thanks.

View 6 Replies View Related

Moving SQL7 Log File

Oct 25, 1999

To all,

How can I move the log file from drive C: to drive D:. I do not need to keep the log file contents and can start new.

Thanks,

Frank

View 2 Replies View Related

Moving A File Using Activex In DTS

Jun 17, 2004

I am attempting to export a records to an excel file using DTS and then use activex to rename the file to include the date it was run. To do this i just move the file.

However when the script is run, it fails saying that permission is denied on the "move" line. I have seen other reports saying that permission is denied when using the "CreateObject" however i have implemented the changes it says, ie/ adding the SQL Agent login using the DCOMcnfg utility and renaming the DefaultAccessPermission key in the registry, with no success. It also doesnt seem to fail on that line anyway.

I have also added all the groups and usernames with full control to the security of the folder the file is in to no avail either.

'**********************************************************************
' Visual Basic ActiveX Script
'************************************************************************

Function Main()
Main = DTSTaskExecResult_Success

Set fso = CreateObject("Scripting.FileSystemObject")

'
Set bFile = fso.GetFile("c:DTS reportsoutput.XLS")
aYear = year(now)
aMonth = month(now)
aDay = day(now)
filename = "output" &aYear & aMonth & aDay & ".xls"
bFile.move ("c:DTS Reports"&filename)
'fso.MoveFile "c:DTS Reportsoutput.xls", "c:DTS Reports"&filename

Set fso = Nothing

End Function

Does anyone know what kind of permissions the folder the file is in must have in order for this script to work? Any help would be greatly appreciated.

Thanks

View 2 Replies View Related

Moving A Log File Location

May 14, 2008

I've got some users that created a database with the log file on a drive that doesn't have a lot of space. I'd like to truncate the log and move it to a different drive. I can truncate it, but is moving it as easy as changing the files properties through SSMS?

Thanks

View 2 Replies View Related







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