Hi all
I am looking for the best method to automate a website's database management. Lets say I have a user registration database and the users register. This sends an automated email to the user with a link to activate the users registration. If the user does not register within 24 hours, his registration must be automatically deleted from the database using a stored procedure.
I know how to do this using the global.aspx file, however there must be an alternative way of doing this, especially if the database is an SQL database. I do not know how much MSSQL server access is given to a developer by an as ISP who hosts the website.
Can anyone tell me what would be the best method to use.
Thx
Warren
I'm running 2000 databases in a 2005 server. Can anyone tell me if there are adverse effects in doing this? As I understand it, the 2005 performance benefits are available to databases running as 2000(Ver80) But some of the new futures may not be available.. And any documentation from Microsoft/white papapers regarding this subjects are appreciated..
I'm having some problems debugging SQL Server stored procedures on a SQL Server 2005 server. I have installed Visual Studio 2005 on a workstation running Windows XP, now I'm trying to debug a ASP.Net web application that has some code that executes the stored procedures on a Windows 2003 Server running SQL Server 2005.
I opened VS2005 ... created a connection to the SQL Server 2005 instance ... open the Stored procedure ... right click the stored procedure name and selected Step into Stored Procedure and the following message is displayed:
Unable to start T-SQL debugging.Could not attach to SQL Server process on 'ServerName'.
This Might be a really simple thing, however we have just installed SQL server 2005 on a new server, and are having difficulties with the set up of the Store Procedures. Every time we try to modify an existing stored procedure it attempts to save it as an SQL file, unlike in 2000 where it saved it as part of the database itself.
Hi! I use sql 2005 express on my computer for testing. The server that hosts my site is a sql 2000 server. Therefore I tuned the one database I use down to sql 8. When I create stored procedures from web developer express, to the local sql 8 database I have in my sql express, it works nice. But when I copy all my files and my stored procedure to the webhost, it doesn't work.
Do you guys have any suggestions? Thanks in advance.
i have a assignment on hands to transfer store procedures of 2005 to 2000. I have tryed by scripting SPs and then runing them in 2000 QA, but it gives me error every time ....... so please help me to resolve this problem.
Hi, I need to write a script to run an automation in MS SQL 2005. It will run every 10 hours. What the script will do is just import a .cvs file into a database table. Can someone let me know how can I acheive this? Thanks in advanced.
Stupid question but please be gentle and answer anyway please....
Background: We have SQL Server 2003 (32bit) running on our servers. Our .Net applications (from old release of VS) are still running on them and using the old databases. From what I understand there is no immediate plans to upgrade the servers. However the developers were just given this new upgrade (2005) SQL Server and VS (and fixing depreciated code etc in the .net apps).
Question: Can the applications and new stored procedures written via the 2005 environment be deployed successfully on the 2003 Servers? Same goes with Reporting Services?
Does enabling/disabling Data Execution Prevention have a performanceimpact on SQL 2000 or SQL 2005?For SQL best performance - how should I configure for:Processor Scheduling:Programs or Background servicesMemory Usage:Programs or System Cache
I am a bit new to the MSSQL server. In our application, we use so many SQL queries. To imporve the performance, we used the Database enigine Tuning tool to create the indexes. The older version of the application supports MSSQL 2000 also. To re-create these new indexes, I have an issue in running these "CREATE INDEX" commands as the statements generated for index creation are done in MSSQL 2005. The statements include "INCLUDES" keyword which is supported in MSSQL 2005 but not in MSSQL 2000.
Ex:-
CREATE INDEX IND_001_PPM_PA ON PPM_PROCESS_ACTIVITY
We have vendor from we puchased an application. It is going into production next week and we have our final set of table ddl and it includes stored procedures.
Since I am fairly new to MSSQL 6.5, and forced to include the stord procedures within the application, I would like to get some feedback as to whether or not stored proceures are efficient or are going to cause me problems?
Aside from periodically running sp_recompile what else will I need to do?
Any information that can be provided willl be greatly appreciated. THanks.
Ben writes "I have a sql script that doesn't function very well when it's executed on a SQL 2000 server.
The scrpt looks like this:
--------------------------------------------------------------------------------------------------- USE [master] GO IF NOT EXISTS (SELECT * FROM master.dbo.syslogins WHERE loginname = N'SSDBUSERNAME') EXEC sp_addlogin N'SSDBUSERNAME', N'SSDBPASSWORD' GO GRANT ADMINISTER BULK OPERATIONS TO [SSDBUSERNAME] GO GRANT AUTHENTICATE SERVER TO [SSDBUSERNAME] GO GRANT CONNECT SQL TO [SSDBUSERNAME] GO GRANT CONTROL SERVER TO [SSDBUSERNAME] GO GRANT CREATE ANY DATABASE TO [SSDBUSERNAME] GO USE [master] GO If EXISTS (Select * FROM master.dbo.syslogins WHERE loginname = N'SSDBUSERNAME') ALTER LOGIN [SSDBUSERNAME] WITH PASSWORD=N'SSDBPASSWORD' GO GRANT ADMINISTER BULK OPERATIONS TO [SSDBUSERNAME] GO GRANT AUTHENTICATE SERVER TO [SSDBUSERNAME] GO GRANT CONNECT SQL TO [SSDBUSERNAME] GO GRANT CONTROL SERVER TO [SSDBUSERNAME] GO GRANT CREATE ANY DATABASE TO [SSDBUSERNAME] GO USE [master] GO IF EXISTS (select * from dbo.sysdatabases where name = 'ISIZ') DROP DATABASE [ISIZ] GO USE [SurveyData] GO exec sp_adduser 'SSDBUSERNAME' GRANT INSERT, UPDATE, SELECT, DELETE TO SSDBUSERNAME GO USE [SurveyManagement] GO exec sp_adduser 'SSDBUSERNAME' GRANT INSERT, UPDATE, SELECT, DELETE TO SSDBUSERNAME ---------------------------------------------------------------
I need to be converted to a script that can be executed on both MSSQL 2000 and MSSQL 2005.
I was wondering if somebody there could help me with this problem?!
I've been tasked to move our production databases on MSSQL 2000 to 2005. I've supported MSSQL since version 6.5 and performed migrations to successor versions.
Current Environment is MSSQL 2000 32-bit with current Service Packs.
I've performed mock migrations on Test servers upgrading all Production instances simultaneously from MSSQL 2000 to 2005 32-bit. The Test environment is identical to Production minus server name, IP etc. Also I have a separate server with MSSQL 2005 installed where I use the DETACH / ATTACH and BACKUP / RESTORE method for migration / acceptance testing. There are approximately 30 databases totaling 70 GB. This has gone as expected and fairly successful. Vendors have been coordinated with to update code and staff for acceptance testing.
I'd prefer going directly to MSSQL 2005 64-bit instead if possible due to memory benefits etc. This is where I'd like some feedback prior to borrowing a 64-bit server for testing.
Upgrade options:
1. Is it better to migrate from MSSQL 2000 32-bit to 2005 64-bit via: a. DETACH / ATTACH b. BACKUP / RESTORE c. Is one method more advantageous relating to the end result? 2. Regarding XP clients, have issues been experienced with the default SQL Server driver or is an alternate recommended for XP clients to connect to a MSSQL 64-bit server databases? 3. If you have performed this migration and have relevant experience please pass them along.
I am running MS SQL Server 7 with SP3 installed and am having some problems getting replication to work correctly. I want to replicate all tables from one database to another database on the same server. I can setup replication, add publications and add subscriptions without any problem and all goes well until the replication process starts when the job aborts because it cannot find the sp_MSins..., sp_MSupd... or the sp_MSdel... stored procedures. I have used the New Publication wizard to create a Transactional publication, published all tables and allowed the wizard to use the default stored procedures which it says will be created when the subscribers are initialized but although I have created push subcriptions the stored procedures are never created and hence the replication fails whenever the job runs.
I have SA access to the databases concerned and as far as I am aware the jobs are running as my login - can anybody help me out as this is beginning to drive me nuts.
I need to run stored procedures which are currently run on server A(located in another city),by connecting myself to it through my laptop running on SQL server 7.0(only client components installed)on NT workstaion4.0. Can anyone tell all the steps involved to run those stored procedures everyday.Even I need to monitor Server A from my laptop.Please advice...Urgent!!
I have two similar stored procedures which I'm running. One runs andone doesn't. I can run both with no problems in SQL Enterprise (7.0standard) and have checked the permissions and am happy with them.Whilst the statements in each sp are different, I'm calling them inexactly the same way (using Delphi 5 Windows 2000). I don't get anytrappable errors.I ran a trace on what was happening and I get two different set ofresults. This is what I'm trying to get my head around.Client Trace (runs)1 09:09:44 Log started for: Swift Client Import Utility2 09:09:48 SQL Prepare: MSSQL - :1 =dbo.CBFAUpdateSwiftClient;13 09:09:48 SQL Misc: MSSQL - Set stored procedure on or off4 09:09:48 SQL Data In: MSSQL - Param = 1, Name = Result, Type= fldINT32, Precision = 0, Scale = 0, Data = NULL5 09:09:48 SQL Misc: MSSQL - Set statement type6 09:09:48 SQL Execute: MSSQL - :Result =dbo.CBFAUpdateSwiftClient;17 09:09:48 SQL Stmt: MSSQL - Close8 09:09:53 SQL Connect: MSSQL - Disconnect NEW9 09:09:53 SQL Connect: MSSQL - Disconnect NEW10 09:09:53 SQL Connect: MSSQL - Disconnect PASSTHRUEnquiry Trace (Doesn't run)1 09:08:21 Log started for: Swift Client Import Utility2 09:08:24 SQL Prepare: MSSQL - :1 =dbo.CBFAUpdateSwiftEnquiries;13 09:08:24 SQL Execute: MSSQL - :Result =dbo.CBFAUpdateSwiftEnquiries;14 09:08:50 SQL Prepare: MSSQL - :1 =dbo.CBFAUpdateSwiftEnquiries;15 09:08:50 SQL Misc: MSSQL - Set stored procedure on or off6 09:08:50 SQL Data In: MSSQL - Param = 1, Name = Result, Type= fldINT32, Precision = 0, Scale = 0, Data = NULL7 09:08:50 SQL Misc: MSSQL - Set statement type8 09:08:50 SQL Execute: MSSQL - :Result =dbo.CBFAUpdateSwiftEnquiries;19 09:08:50 SQL Vendor: MSSQL - dbrpcinit10 09:08:50 SQL Vendor: MSSQL - dbrpcexec11 09:08:50 SQL Vendor: MSSQL - dbsqlok12 09:08:50 SQL Vendor: MSSQL - dbresults13 09:08:50 SQL Vendor: MSSQL - dbnumcols14 09:08:50 SQL Vendor: MSSQL - dbcount15 09:08:50 SQL Stmt: MSSQL - Close16 09:08:50 SQL Vendor: MSSQL - dbdead17 09:08:50 SQL Vendor: MSSQL - dbcancel18 09:08:56 SQL Connect: MSSQL - Disconnect NEW19 09:08:56 SQL Connect: MSSQL - Disconnect NEW20 09:08:56 SQL Connect: MSSQL - Disconnect PASSTHRU21 09:08:56 SQL Vendor: MSSQL - dbdead22 09:08:56 SQL Vendor: MSSQL - dbfreelogin23 09:08:56 SQL Vendor: MSSQL - dbcloseI would have thought that these would be nearly identical. They callsp's on the same servers in the same way, so the call to do thisshould (in my mind) be the same.I can post the sp's if anyone thinks they are of relevance.I can of course set up these stored procedures to run at a certaintime, but I'd like to try and understand this a little more.Thanks in advance.Ryan
Hi, Can someone help me with this problem. I have a stored procedure in SQL Server that updates a particular table. When I run it in SQL server Query Analyser, it works fine. But I want to invoke this stored procedure when I click a button on an MS Access Form. The code I'm using is:
Dim cn, cmd Set cn = CreateObject("ADODB.Connection") cn.Open "SQL" //Data Source Name Set cmd = CreateObject("ADODB.Command") Set cmd.ActiveConnection = cn cmd.CommandText = "LoadApplicants" //Stored Procedure Name cmd.CommandType = adCmdStoredProc cmd.Execute
for some reason only a few records are updated everytime I click on the button. Is there any reason why this is happening?
I have installed SQL 2005 and was trying to run one of the Samples. I installed SQL as an instance, but when I run the setup script, it fails because it can not assign permissions to the ASPNET account.
It looks like it thinks the account is ServerNameInstanceNameASPNET, but it should be ServerNameASPNET.
I have successfully moved my data from a SQL Server 2000 hosting site to a SQL Server 2005 hosting site. I Made a backup of my database using Enterprise Manager (2000) and imported the database tables using SQL Server Management Studio (2005). I do not know how to move the 25 or so stored procedures that I have in SQL Server 2000. I have a very short amount of time to figure this out and am hoping that someone can give me a brief step by step answer on how to get this done. I would appreciate any information you can provide. Thank you!!
Hi there,I have a data manipulation process written in a Nested Stored procedurethat have four levels deeper. When I run these individual proceduresindividually they all seems to be fine. Where as when I run them alltogether as Nested proces (calling one in another as sub-procedures) Logfile is growing pretty bad like 25 to 30GB.. and finally getting kickedafter running disk space. This process is running around 3hrs on a SQLserever Standard Box having dual processer and 2gb ram.This procedures have bunch of bulk updates and at least one cursor ineacch procedure that gets looped through.I was wondering if anybody experienced this situation or have any clueas to why is this happening and how to resolve this?I am in a pretty bad shape to deliver this product and in need of urgenthelp.Any ideas would be greatly appreciated..Thanks in advance*** Sent via Developersdex http://www.developersdex.com ***
Developers have complained that some of their jobs are taking too long to run. I used Profiler to trace one really bad performer and could see that the code was making one pass through its loop in about 7 seconds. I found one select statement that was using the majority of the time, plugged it into query analyzer and looked at the execution plan. It was using an index but not very efficiently. I then ran it through index analysis and it recommended a new index. This was cool! The new index helped.
But, the job continued to run very, very slowly - over a week before it died! I ran another trace, and it was hanging for 10+ seconds in random locations. Sometimes it would be on a database call, sometimes it would be on a simple SET @variable = value statement. There was no pattern. According to the sys admin, the server itself did not look taxed. It does not appear to be a locking problem because of the random location of the stall. The application and server are only lightly used at this point, so I would hate to see how bad it could be if it was busy.
I am still fairly new to SQL, though I have years of DBA experience. I would appreciate any ideas - especially the obvious things that I am probably not considering. I have logged a call with Microsoft but they haven't gotten back with an answer. I sent them a trace file and a perfmon file, neither of which showed them anything.
I have a strange situation when I try to execute the same Stored Procedure on servers with different processors. Both servers are running the SQL SERVER 2008 R2 version with all updates.
All updates bios, disk controller, firmware, were applied on the new server.
New Server: (considerable difference in processing time) Stored Procedure without encryption, runs at about 02:16hs Stored Procedure with encryption, runs at about 08:00hs
Server Processor:
Intel (R) Xeon (R) CPU @ 2.60GHz E5-2697 v3
Old Server: (There Are No difference in processing time) Stored Procedure without encryption, runs at about 01:00hs Stored Procedure with encryption, runs at about 01:00hs
Server Processor: Intel (R) Xeon (R) CPU @ 2.7GHz E5-2697 V2
In terms of configuration, the server 2, have lower technology, lower bus, lower number of processors.
I believe that combination of Hardware/SO/Sql Server has a potential performance loss when running encrypted SP.
Below is a migration plan that I've compiled to migrate SQL 2000 DTS packages to SSIS 2005. Once these DTS packages have been migrated i will need to create a job and schedule them in SQL 2005.
I would appreciate and feedback or questions on this migration plan.
Migration DTS 2000 packages to SSIS 2005:
1. Will need to save the current production DTS package as structure storage file. We do not have a UDL file. We set the data connections within each DTS package. 2. Go to Sql 2005 - ManagementLegacyData Transformation Services - right-click and open previous saved structure storage file. 3. Modify the DTS data creditentials to reflect the SQL 2005 connection data. Modify any SQL 2000 MAPI settings to utilize SQL 2005 new database mail. Save the package on SQL 2005. 4. After the modified DTS package has been updated and saved on SQL 2005, save this file as a structure storage file. 5. go to BIDS. Create a new SSIS project. Right-click on SSIS packages and select Migrate DTS 2000 package. This will migrate over the DTS 2000 package with the updated SQL 2005 data creditentails. 6. click on the package properties - protectionlevel and change it to dontsavesensitive. 7. right-click and select package configurations..., select to store data creditentials in xml format. 8. right-click on execute DTS 2000 package task, select Edit... and click on Load DTS2000 package internally. This will embed this task into the new SSIS package. Test the package. Continue if successful. 9. Use SSIS deployment functionality to move the package over to SQL 2005 Integration Services. Right-click on package and select Run Package, if successful, create a job and schedule it to run on SQL 2005 Agent. 10. When creating the Job under SQL Agent, change the Owner: of the job to reflect the owner of the new SSIS package. Schedule the job.
I've just coming up to speed on SSIS 2005. Therefore, this is what i've been able to piece together up to this point and I'm looking for some industry advice/feedback on whether or not this is a good migration plan. I need to provide a migration plan to management by 2/18. Thanks
when i am running a Stored Procedures, system always returns me error message below and Stored Procedures stops. please help
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver] Received an unrecognized datatype 0 from TDS data stream
sometime it returns error messge like, TDS Buffer Length Too Large or Unknown token received from SQL Server
or Protocol error in TDS stream or Bad token from SQL Server: Datastream processing out of sync. or Invalid cursor state or TDS Buffer Link Too Large or Function sequence error
I have installed MSSQL 2005 on my D: drive of my windows 2003 server, but now need to install MSSQL version 2000 b/c I realized I have one less license than I thought I had. I have build no databases, only the default information. Can I install another instance (being the 2000 instance) on the same drive? If I can't, can I install it on the Crive without a lot of issues???? Or would it be easier to remove 2005 and just start from scratch? The sql version is 9.0. Any help or comments would be greatly appreciated.!!!!!
Hy all. My main goal would be to create some kind of map of the database, wich contains information of all connecting fields, including wich fields has key references to the other one and wich table. I'd like to have a table wich shows all the database connections tablename, field, field/table_key (from or to the key points), field_key_type (prymary or foreign) So I thaugh to get sp_fkeys and sp_pkeys from master table and inner joining their results, but I simplay cannot "catch" their result sets. The script must have been written in SQL. Obviously I'd like to do this: SELECT * FROM EXEC sp_fkeys @table_name = 'xy' of course it is not working this way, but I'd like something like this.
Hello, I think now MS SQL 2005 support packaging database object into schemas which may be granted access by any of the db users, while SQL 2000 only we could use the database creator user instead of schema. my case is i am working in a system with more than one module, e.g. HR + TaskManagemt. Both HR and TaskManagement objects are in the same database, and there are some common objects. I want to isolate the HR objects from the TaskManagemt objects, so i can package any module separated from the other, suppose i want to buy only the HR module, so that i want only to exctract the HR Object + the common objects but not the TaskManagement objects. So how can i accomplish such operations using SQL 2005 schemas AND using SQL 2000 users. P.S. i have two servers one with 2000 and the other with 2005, so i want to find solutions for both 2000 and 2005 Thanks in advance