SQL Server Frequently Asked Questions FAQ

Sep 14, 2005

If you have followed a link to this page (i.e. the URL contains "SearchTerms=xxx") please scroll down to see items of interested highlighted

This list of SQL Server Frequently Asked Questions (FAQ) was originally compiled in August 2005 based on the most frequently "read" posts on SQL Team. Since then new links have been added as topics become popular - so it might be better referred to as FGA - Frequently Given Answers!

NC=Indicates that the Article has NOT been checked for relevance. As time goes on these are getting fewer and fewer
The latest change is in Red
Recent changes are in Teal

URL to link to this post: 17Nov2005
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=55210&SearchTerms=
Followed by either "Keyword1,Keyword2" or "PhraseWord1+PhraseWord2"

The icon allows you to RightClick-CopyShortcut to provide a link to this topic with appropriate keywords - I got bored of having to make them manually! 07Mar2006 Stats

Homework
I put this one at the top, in case you don't read any further. To find out if your homework will be answered on this forum you should see if it qualifies:
Requirements for homework questions 07Mar2006
Example of Failure to meet the minimum requirements 07Mar2006
Learning SQL www.sql-tutorial.net 07May2007
www.firstsql.com/tutor.htm 07May2007
www.w3schools.com/sql/default.asp 07May2007

Why?
Why is my LDF Log File so big / getting bigger / bigger than my MDF 14Oct2005

How to

How to ask a question on SQL Team and get a quick answer - i.e. the information you need to provide 06Nov2006
How to format your question or a reply (in particular see the [code] option 18Sep2007
how to encrypt and decrypt my password 07May2007
Rounding up/down to nearest multiple (e.g. order in dozens, buy at least 30) 28Sep2006
Replace multiple spaces, or other character, with single space 28Sep2006
Generate a Random String 13Sep2006
String comparison 24Jul2006
Article: Images and SQL Server
How to get Images or blobs into SQL table (NC)
Inserting Images as BLOB in SQL server table (NC)
How to use DeBUG window in QUERY Analyzer (NC)
Use a Parameter in the Top clause
Dynamic SQL or How do I SELECT TOP @var records?
Can't insert NULL into table with unique key (NC)
Efficient paging of recordsets with T-SQL
Article: Paging in SQL 2005 07May2007
Execute dynamic SQL that is longer than varchar(8000) 05Oct2005
Convert multiple spaces to single spaces 14Oct2005
Making Upper/Lower Case Sensitive comparison 27Oct2005
Convert to Proper Case (each word starts with capital) 19Feb2006
Deleting a massive number of rows 04Mar2006
Combine values from rows into a column 05Oct2005
i.e.
FOO 1
FOO 2
becomes:
FOO 1,2

CSV / Splitting delimited lists
WHERE IN @MyCSV
Article: Passing a CSV or Array to a Stored Procedure (NC)
Best split functions
and Concatenating data from rows with same GroupBy column
Triggers
Triggers to audit changes
trigger to keep tables matching
Set Update/Modified date column using a trigger 02Nov2005
Deactivating a trigger 07Feb2006

SQL Team Articles
Article: Identity and Primary Keys - and Surogate Keys See also
Article: Sending SMTP Mail using a Stored Procedure (NC)
Article: Dynamic ORDER BY (NC)
Article: More Trees & Hierarchies in SQL (NC)
Article: Using SELECT to INSERT records (NC)
Article: Deleting Duplicate Records
Article: Returning a Row Number in a Query (NC)
Article: Calculating Running Totals (NC)

Datatypes / Collation

GUIDs (NC)
IsGUID check GUID is valid 01Aug2007
DATALENGTH() and LEN() 21Sep2005
Compare BIT columns and a BitMask column 05Jan2006
Collation conflict in Assignment or WHERE clause 05Feb2006
(See "Developer / Techie stuff" below for some other Collation links)

Datatypes - Dates

Time Only Function: F_TIME_FROM_DATETIME 29Apr2006
Date/Time Info and Script Links (including UNIX time) 16Apr2006
Date formatting (
Format Date/Time (NC)
last date of the month (NC)
Getting the date portion of a datetime value or
Round a date to Year, Quarter, Month, Day, Hour or Minute
How to get date in t-sql (NC)
compare date with current date (NC)
convert varchar to datetime (NC)
Compare dates regardless of time? (NC)
Convert varchar to date (NC)
Time in Analog (NC)
Start of Week Function (NC)
Earlier date than 1/1/1753

Techniques

Prevent Administrators accessing a database 14Sep2006
SELECT vs SET 26Sep2005
What is a cursor, Why is it bad? 23Sep2006
Cursor or Not (NC)
TSQL/ SP Best Practices (NC)
case-sensitive (NC)
User-Defined string Functions Transact-SQL (NC)
Passing an array into a stored procedure (NC)
Comparing two tables or views easily (NC)
All Tables in All Databases (NC)
Better Phonetic Matching Algorithm (A better Soundex)
Levenshtein Edit Distance Algorithm (A better Soundex)
Fuzzy matching 01Aug2007
Find tables with no PK (NC)
Function: HTMLDecode (NC)
How to protect errorlogs to tables from rollbacks (NC)
Distance of Zip/Postcodes
Great Circle Formula 07May2007
Haversine Formula 07May2007
Accuracy v. Speed 07May2007 See also here, here, here, here and here and here
Upsert - combined Update/Insert Procedure 01Aug2007 and here
Display all columns but only for rows with the most recent date 01Aug2007

Developer / Techie stuff

Changing column names on referencing objects 07May2007
When was DB object last updated 07May2007
How to clear the whole database 07May2007
Move / Script Development Database Changes to Production Database / Ship Application updates 04Nov2006
Script to analyze table space usage 11Oct2006
What version, and Service Pack, of SQL Server am I using? 23May2006
SQL Beautifier 13Apr2006
Performance / System Monitor / PerfMon - preferred values for counters 04Apr2006
SQL Server 2000 Knowledge Base Articles - updated every 3 days 21Jan2006
Concerns about SQL 2000 SP4 08Jan2006
Support stops for SP3a AND installing sp4 on cluster 26May2006

How to read Mssql transaction log file
Compare data in two tables / two databases 31Oct2005
Recommended books 07Oct2005
Good tools for DBAs 06Oct2005
Best SQL Security Method (NC)
Some query optimalisation (NC)
Requirements for Horizontal Partitions
Multiple SQL Server 2000 Instances (NC)
Primary Key v. Unique Index (NC)
HOWTO Run SQL Profiler without sysadmin rights (NC)
upgrade from SQL7 to SQL2000 (NC)
xp_cmdshell execute right (NC)
Monitor object usage over time (NC)
size of user tables in a database (NC)
Changing Column Length (NC)
Add, Sub, Mul, Div With Really! Big Numbers (NC)
So you're a DBA eh?!
Why I'm not a DBA (NC)
Do you S-Q-L or Sequel (NC)
Interview questions (NC)
More Interview questions 11Sep2006
Best steps to becoming a DBA (NC)

Developer / Techie stuff - Collation

Bulk Delete of Records 07May2007 and locking issues 01Aug2007
Deleting lots of Records from a large table 01Aug2007
Synchronising data using staging tables 07May2007
Version Control 07May2007
how to change Collate on the server 20Sep2005
How to change default collate in SQL 20Sep2005
Cannot resolve collation conflict for equal to OP 20Sep2005
different Collation Settings between Databases 20Sep2005


Database Design and Structures

Codes - Common Lookup Tables CLT 04Jun2006
Good table naming convention 09May2006
Naming Store Procedures 09May2006
Recursion / Hierarchy 29Apr2006
Hierarchies (NC)
Normalisation (NC)
NULL opinion? (NC)
Finding evidence of sql injection attack
Security Testing: SQL Injection 09May2006


Locking

Using the NOLOCK hint 07Jun2006
how does row locking work (NC)


EMail

sp sending mail (NC)
CDOSYS Send Email (NC)

XML

SQL Server 2000 XML (NC)
Adding an XML Root Tag
Handling tricky namespaces in OpenXML

Backup / Restore / Replication / Jobs / Houskeeping

Backup
How Backup works
What type of backup should I use? - Full, Differential, Transaction? Should I shrink the log? 22Jan2006
Automating Backups - Scripting v. Maintenance Plan / Wizard 08Mar2006
Backup to Disk, or direct to Tape? 05Dec2006

Disaster Procedure Checklist I think I have a database corruption, how do I mitigate any further damage and get upright again? 07May2007
How I Rescue Data from Corrupted Databases 07May2007
Disaster Recovery Plan 07May2007
Quiesce the SQL Service to enable low-level copy 01Aug2007

Restore
RESTORE syntax / example
Restore SQL 2005 to SQL 2000 via Downgrade 07May2007
Restore Full and all TLogs backups based on files in disk folder 07Dec2006
Move database to a new server (with minimal downtime) 16Feb2006
Moving to a new sql server 25Jun2006
Fix Orphaned Users (after a Restore or moving DB to a different server)
Script User Logins after a Restore 01Aug2007
and
Scripting users & logins from one server to another (e.g. after moving DB to a different server) 25Jul2006
how long will take to restore a 10 gb?
All I have is the .bak file
Restoring .BAK file to a different server?
Unable to restore/attach a MDF file (single file attach / sp_attach_single_file_db)
See also: This and this and this


Shrink Database / Files

Shrinking TEMPDB 19Apr2006
Database Shrinking 09Jan2006
Log Shipping -Shrinking Log and Data files (NC)
MSDB Massive msdbdata.mdf

Housekeeping / Maintenance

Tara Blog Houskeeping Routines 06Oct2006
Index Tuning Wizard 07May2007
User Rights for SQL Service 07May2007
When was SQL Server last restarted? 07May2007
Optimising your indexes with DBCC INDEXDEFRAG 06Oct2006
Detach Move Db & Log File Reattach 17Mar2006
Rebuilding Indexes
DBCC CHECDB, CHECKTABLE, NEWALLOC (old)
Suspect Databases after Power Cut?
Jobs failing (NC)
Reindex All Tables in All Databases (old)
deleting replication (NC)

Export / Import / DTS

Copying/backing up DTS Packages (NC)
Export to Excel (NC)
Generate INSERT statements for N rows of data
Tool to script database records? (i.e. generate INSERT statement script)
How to convert DATE Format from DD/MM/YY to MM/DD/YY in DTS (NC)
Importing an Excel File with DTS (NC)
Is DTS Secure for credit card backup to Access? (NC)
Winzip in scheduled DTS Package (NC)
Article: Using BULK INSERT to Load a Text File (NC)

Output / Reporting / Formatting

Pivot table (NC)
Article: Dynamic Cross-Tabs/Pivot Tables (NC)
which led to:
More Dynamic CrossTabs using T-SQL 04Aug2006 (Jeffs Blog)

Error Messages

SQL Server does not exist or access denied (NC)

Connections

Linked Server Newbie Question (NC)

Configuration / Hardware

/3GB in boot.ini on Win2003 standard 19Oct2005
SQL memory /3gb /PAE AWE 19Sep2005
SQL Server Standard & 4GB memory
Using AWE option in SQL
Increasing SQL Server Memory

MSDE

MSDE Setup fails (NC)
MSDE Install Issue (NC)
Installing MSDE on XP Pro (NC)
Backing up MSDE database (NC)

SQL 2005 / Yukon

Migrating to SQL 2005 Hints and Tips 01Aug2007
SELECT not allowed in Yukon/SQL2005? (NC)
Download Yukon/SQL2005 (NC)
SQL Server Management Studio (NC)

MySQL, Oracle, and the others

MySQL not as good as MS SQL?
Migrating from Oracle to SQL Server

Other

SQL Reporting Service SP2? (NC)

Got an hour .. or ten ... to spare?

Would you work at Elwoo's office?
Simple Quiz
What is a Yak? 07May2007

View 20 Replies


ADVERTISEMENT

SQL 2012 :: Blocking Frequently Report Server TempDB

Aug 27, 2015

How to solve the below blocking issue

One of our production server is configured with Always on with sql cluster.

We are getting frequently blocking

Waiting Resource Key Type: Key
WaitType: LCK_M_S
WaitResourceDatabaseName : ReportServerTempDB
WaitingSessionProgramName: Report Server
BlockingSessionProgramName: Report Server
WaitCommandType: Select
WaitingCommandText: Create Procedure dbo.checksessionLoak @sessionID...

View 1 Replies View Related

SQL Server 2008 :: File Group Is Running Out Of Space Frequently

Sep 1, 2015

We are receiving following alerts frequently about 1:40 AM in the morning. We have backups running on 11:00 PM everyday and rebuild job running at 2:00 AM. Not sure the exact cause of this error.

Error:

The file group "PRIMARY" for the database "tempdb" in SQL instance "MSSQLSERVER" on computer "XYZ" is running out of space.

tempdev Initial size : 133,100 MB Growth: By 10 percent, Limited to 140000 MB
templog Initial Size : 5,475 MB Growth: By 10 percent, Unlimited

View 9 Replies View Related

SQL Server Admin 2014 :: Update Statistics On Frequently Updated Tables

Dec 23, 2014

I'm working on databases where statistics of some indexes (tables) are changing too frequently. Once I update them manually, one minute after they get 10-20% change, and five minutes after they get over 100% change. Tables get updated very frequently (multiple times in a second).

When I run a query to read from sys.stats, sys.dm_db_stats_properties and other dynamic views, I see that they were last updated when I did it manually, but the change rate overpassed the 500+20% (tables have multiples of 10K rows). Auto create and update statistics are set to true on all databases, and I don't know why sql server does not do that automatically.

View 2 Replies View Related

SQL Server Admin 2014 :: Running Frequently Transaction Log Backup During Integrity Check DB

Jul 6, 2014

Running Frequently Transaction logbackup during Integrinty check DB /optimization job will cause any issue /impact as duration will extend ...

View 2 Replies View Related

Outlook Runs Very Slow Frequently Non-response, SQL Server Using Up To 1GB Memory - VISTA && Office 2007

May 14, 2008

When I launch Outlook, it takes forever for the program to finally open. With any inbound email, it stops processing whatever is underway at the time....and frequently there is a 2-3 second lag between keyboard input and what appears on the screen. SQLserver is usually consuming upwards of 1-gb of memory....help. Mike

View 1 Replies View Related

Asked A While Back - Think I'll Try Again!

Jul 20, 2005

This pertains to SQL Server 2000Do others have the problems that we have in our company, where we havea field from a table, and need to know all the SQL Server processesthat may change that value? I'm still hoping somebody can tell me of atool, or set of queries or something that will document the fields inthe tables and the processes that affect them, along with the valuesthat it sets. For example:TableA.FieldA:sp_InsertNewRec: sets field to Null when new record createdsp_ChangeStatus: sets field to the value of the parameter passed intr_LogChanges: sets field to be the current datetimeMaybe we're just too sloppy at my company, but it seems to be fairlyobvious need to have some sort of automated process that can providethat documentation. With thousands of fields, hundreds of storedprocedures, triggers, DTS's etc..., documenting this information is aVERY daunting task. Any help at all would be appreciated.Gary

View 1 Replies View Related

Question Never Asked About SQL ExPress.

Nov 10, 2005

Hello,

I understand that SQL Express is a free tool and its placed between Access and SQL 2000 / 2005.
I also understand that it supports Database upto 4 GB, which is quiet sufficient for any small or medium sized
company.

My question is a bit confusing... let me explain. We get Access database free by the hosting comany. We just have to
pay extra if we need SQL 2000 or SQL 2005 support, depending on size.

Will we get SQL Express Free support as its a lready free for all. In Access case, we just have to upload .mdb file along
with rest of our code, what is the procedure for uploading SQL EXPRESS data. I believe since its a light weight
tool,all the procedures must be same like Access.

Pl. guide with more details.

View 1 Replies View Related

A Probably Over And Over Again Asked Question Of Syntax - Help Please

Oct 15, 2007

Dear GroupI'd be grateful if you can provide me with a hint for the following:Fields Table ContactContactIDFirstnameLastnameFields Table ContactMethodContactMethodIDContactMethodTxtContactMethodTypeIDLinked by Tables:Fields Table LkTbl_Contact_ContactMethodLkTblIDContactIDContactMethodTypeIDFields Table ContactMethodTypeContactMethodTypeIDContactMethodThe purpose of this construct is that I keep all contactmethods suchas Email, Mobile, Home Work, Web in table ContactMethods. Whether it'se.g. an Email or Mobile is identified through the ContactMethodType.That enables me that a Contact can have 3 Mobile Numbers, 2 Emailaddresses.For the sake of simplicity, lets say I want to return the Contact Nameand Home, Work and Mobile numbers. Not all of them but the firstmatching record of each from the ContactMethod table.I must note that the contents of table ContactMethodType for columnContactmethod looks like this:EmailMobileHomeWorkWebI do:Select Firstname, Lastname, Home, Work, Mobile FROM ContactJOIN LkTbl_Contact_ContactMethod ON(LkTbl_Contact_ContactMethod.ContactID = Contact.ContactID)JOIN ContactMethod ON (ContactMethod.ContactMethodID =LkTbl_Contact_ContactMethodID)JOIN ContactMethodType ON (ContactMethodType.ContactMethodTypeID =ContactMethod.ContactMethodTypeID)The question is, how do I map the result from table ContactmethodTypeto my fields Home, Work and Mobile in the resultset? The Type isidentified in ContactMethodType but I can't figure out how to do thisbest.Your help and suggestions or any other better solution is veryappreciated.Thanks in advance for your help and efforts,Martin

View 3 Replies View Related

I Have SQL Authentication But Can Connect To SQL DBs Without Being Asked To Log In. I Need To Change This.

Mar 13, 2008




Hello, I have several SQL 2000 logins on our servers. I removed the builtin/ groups and only have SQL authentication users, although the server is operating in "Mixed Mode". How can I secure this? I don't understand how we can just connect to any DB without ever being asked to log in. Let me know if you can help. Thanks.

View 4 Replies View Related

I Asked This In Sql Express But Hoping To Get A Different Answer Here.

Apr 24, 2007



Here is my goal please let me know if it is possible.

I have installed sql express on clients machines. I don't want them to be able to view the sp's or the functions. I would like to go as far as not allowing them to see the tables. I tried with encrption but this is still breakable by the user using the DAC.



Does CE

Support transactionscope?

What would I use to create tables and sp's for my sdf database? Server Managment Studio or something else?



Thanks

View 17 Replies View Related

Tis Has More Than Likely Been Asked Before But, How Do I IIS Without Opening External Ports On My Pc?

Apr 26, 2007

Hi Everyone,



I am new to the forum and would like to have a question answered. I want to to install Sql Server Express with advanced services but also want to have IIS installed as well. My question is, how do I install IIS without it opening Port 45? When I installed it, it would not let me finish installation without letting it act as a server. Is there any work around to solve this problem that any of you have managed to use?

View 1 Replies View Related

Urgent: A Simple Question About The Most Asked Topic - DATE

May 7, 2004

Hi,

The subject say it all :)

I have a field which stores date which the datetime datatype... The problem is that I am also getting time information in this stored field.

I just want to extract the date part in dd-Mmm-yy format (e.g. 07-May-04). I tried convert (char (8), MyDateField, 112) but it gives me date in yyyymmdd format. How do I get the results in dd-Mmm-yy format instead?

Thanks.

View 7 Replies View Related

How Do You Handle This Control Flow Issue, Asked Mr. Newbie

May 29, 2007

Greetings,

I have a question about the best method to ensure the proper flow of control within a package. I have three related SQL tasks €“ A, B, and C €“ that must execute in sequence. If any one of the tasks fails then the remaining tasks should not execute because each is dependent on the previous step. (A €œsuccess€? precendence constraint.)

Likewise, I have a second set of SQL tasks €“ 1, 2, and 3 €“ that must execute in sequence. Task 3 should never execute unless tasks 1 and 2 have been successful.

I consider these to be two independent logic paths in the same package and, indeed, when I run the package both task A and task 1 begin running at the same time.

What I€™m not sure of is how to add a new task €“ Z €“ that will execute only after both the A-B-C and 1-2-3 task paths have completed. Diagramatically, this would be like having a €œcompletion€? constraint linking task C to task Z and another €œcompletion €œ constraint linking task 3 to task Z. In other words, the two independent paths merge at task Z. Task Z is an audit step that must always run €“ it emails summaries of the database activities performed by the other tasks.

What has me puzzled is how I get to Z when there is a failure in either the A-B-C path or the 1-2-3 path. As things stand now, the package will never reach task Z if there is a failure in an earlier task because they are joined by a €œsuccess€? constraint.

I thought I could get around this by using a €œsequence container€? but I discovered when I added A, B, and C to a container that I couldn€™t use the €œsuccess€? constraint I needed. I was just guessing that this might be the way to do it.

Can anyone help me with a best practice approach to the control flow issue I face? I€™m new if that isn€™t apparent by my question, so don€™t be afraid to make your answer simple and plain.

Thanks for any help,
BCB

View 7 Replies View Related

Why Do I Have To Update The Statistics So Frequently?

Oct 10, 2000

I have a query that retrieves a single record from searching on two tables.
The statement goes like this...
select sum(amount) from Table1 A union Table2 B on a.id = b.id
where date < ### and date > #### and account = ###

As people are running a particular report, this statement is executed time and
time again to pull up the numbers necesarry for the report. When the report gets slow, I can speed it up by updating the statistics. My concern is that I'm having to update the statistcs every hour; otherwise, the query becomes slow. I have noticed that users are inserting data while users are running the report on one of the tables listed above. I'm sure that's making it become more fragmented and ultimately slowing down the query.
Do you have any suggestion on how I can make the union of these two tables faster? Or is there anything I could do to speed the query besides creating clusted indexes?
Any help would be appreciated....thank you

View 1 Replies View Related

How To Protect A Frequently Real Time DB

Jul 2, 2001

Hi Everybody:

We have a table which needs to be updated 2 million times per day. It hosts all real time transaction. There are 200K records in this table. Would you please to share your experience with me about how to protect/save such table in SQL 2000 from any possible damage?

We plan to use point-in-time backup (every 5 minutes). It still takes at half an hour to recover the whole database. Any new technology from Microsoft or SQL 2000 you can recommend?

Thank you very much.

Joan

View 3 Replies View Related

Identifying Frequently Accessed Tables

Sep 25, 2001

Can any one recommend an approach for identifying the frequently accessed tables and files in a SQL/Server application? Particularly, if the database is stored on raw partitions instead of FAT or NTFS. Thanks.

View 3 Replies View Related

Oracle Listener Stops Frequently

Mar 28, 2004

Hi,

I have Oracle 9i. Oracle listener is aborting by itself after every few minutes giving TNSLSNR.exe failed. While listener is running I can do all the activity on the database.

Please let me know if there is any solution.

Thanks in Advance.
Pushpam

View 1 Replies View Related

Is There Performance Loss If I Delete Frequently

Apr 17, 2008

I use SQL2005 EE to capture the "In Progress Data" from the Devices and have connected it to the Main server-SQL2005 SE thro linked Server. I Run a Job that updates the Main server and Clears the "in Process Data".
Off late I have been seeing that the systems with SQL2005 EE have gone slow ? I have not investigated the reason. But wanted to find out if using this method ,should I need to take additional precautions ?

View 7 Replies View Related

Adding/Appending Records Frequently In SQL

Jan 24, 2008

Hey guys. I need a little help once again, here's the problem:

We are using an attendance system software that adds records in an Access 97 table whenever someone logs in or out of the room (Yes, it's old and I hate it, but it came with the hardware).

So we plan to create a program that lets admins check those login/logout data in an SQL Server 2005 database using a Visual Basic as the frontend.

Our only problem is, how do we transfer data from the Access 97 tables to our SQL tables *everytime* it gets updated? We don't need every detail the Access97 table has (it has IDNo, CardNo, Time, Location, plus other useless stuff). We just need to extract the IDNo(int) and Location(varchar) field(we'll just use getdate() for the Time since the update is done in realtime anyway).

So in a way, we are trying to find out a way to technically sync both tables, just like Database Mirroring style.

Any suggestions?

View 3 Replies View Related

To Archive Content Of A Table Frequently

May 7, 2007

Hi,

In a project with SQL Servcer 2005 the customer is interested to save (archive) content of a table frequently. They want to have possibility to restore the table content as before. I have suggested to export the table every day to a text file and save the file in Visual source safe. If they need there will be possibility to import the text file later. Now I wonder, is there any other way to do archiving of the table content in SQL Server 2005?

Best regards

View 4 Replies View Related

File Group Is Running Out Of Space Frequently

Sep 1, 2015

We are receiving following alerts frequently about 1:40 AM in the morning. We have backups running on 11:00 PM everyday and rebuild job running at 2:00 AM. Not sure the exact cause of this error.

Error:
The file group "PRIMARY"  for the database "tempdb" in SQL instance "MSSQLSERVER" on computer "XYZ" is running out of space. 
tempdev Initial size : 133,100 MB Growth: By 10 percent, Limited to 140000 MB 
templog  Initial Size : 5,475 MB    Growth: By 10 percent, Unlimited

View 8 Replies View Related

Frequently Update And Select Table Locking Problem

Oct 10, 2006

Hi guys,
 
            I faced problem related to Locking and Isolation Level on Table(s).
 
            My problems is there r some tables which r frequently updated, and I also want to fire select query over  those tables every 1 seconds and want to get only committed records.
            In current scenario we start transactions with ReadCommitted Lock for updating records. But in this scenario I can€™t get select query result because of some of recourses r used by transactions so after some time it gives Deadlock error.
 

          So I want solution like both operation run simultaneously and get only committed records at a time of transaction running
            Please help me for solving my problem.

 

View 10 Replies View Related

Questions About SQL Server

Sep 20, 2004

Hi there!

I was wondering if anyone can help answer a few questions in regards to MS SQL Server.

1. In stored procedure, am I able to select a bunch of records and run through each record and depending on a certain value do an update or insert?

2. Using DTS, am I able to schedule the stored procedure to run at certain times during the day?

Many thanks!

Richard

View 1 Replies View Related

PAE SQL Server Questions...

Dec 23, 2004

Hey all,

I'm wondering what command I could issue to see the amount of memory a named instance is using from within the instance itself. We've enabled address extensions (PAE), and task manager no longer shows the correct amount of mem being used by the process. Under perfmon, I've added the object MSSQL$INSTANCENAME:Memory and I'm looking at the Total Server Memory. I'm seeing 4 gigs, when max memory is capped at 2gigs. This must show the server memory and not the instance memory ? Is there some way to see the instance memory ?

Cheers,
-Kilka

View 2 Replies View Related

Two Questions About SQL Server 6.5

Jul 23, 2005

Hi,I copied the DATA directory from a backup ghost image to a new SQL6.5 installation and, after fixing a problem with the directory structure(which caused the databases to be marked as "suspect") I was able to workwith it in a normal way.Opening the company database works without problems. The DATAdirectory seems to be correctly copied. The only problem is that I'm unableto see the scheduled tasks. I'm a using predefined database user (not sa).My questions are:1. Is it normal not to see the scheduled tasks when logged asanother user than the sa or the owner of the tasks ? If it isn't, thensomething went wrong copying the DATA directory (even if SQL didn't markthem as suspect). Any advise or comment about this would be really welcome.2. If it's normal not to see the scheduled tasks, Is there any wayto recover the lost sa password ? The docs containing the password werelost around 4 years ago.Any help would be really welcome,

View 10 Replies View Related

SQL Server Questions???

Jul 20, 2005

Hi Folks,I am a newbie when it comes to SQL Server 2000 and have a Sybasebackground. How can I reset my sa password in MSSQL like we do it inthe runserver file(-p) in sybase??? Also, can I configure replicationusing the standard edition of MSSQL server????ThanksRegardsdba_sybase2003

View 5 Replies View Related

SQL Server Interviewee Questions...

Mar 19, 2001

Does anyone know where i can obtain some SQL Server questions to test interview candidates ??

many thanks
Paul

View 1 Replies View Related

SQL Server Interviewee Questions...

Mar 19, 2001

Does anyone know where i can obtain some SQL Server questions to test interview candidates ??

many thanks
Paul

View 2 Replies View Related

SQL Server Interviewee Questions...

Mar 19, 2001

Does anyone know where i can obtain some SQL Server questions to test interview candidates ??

many thanks
Paul

View 1 Replies View Related

Questions About: ACCESS -&> SQL Server

Nov 3, 2004

Im consulting a financial company on their Access database. It has a back-end with about 100 tables (some close to 100,00 records) and a front-end with all the Forms, Queries, Modules, and Reports. The last few weeks they have had to compact and repair the front end twice a week where before it was a bi-weekly thing.

Im trying to sell them the service of moving everything I can to SQL Server and link it back to the front-end Access GUI, but Im not sure of everything that goes into this process and how long it will take - of course my client needs the process on paper with an estimate timeline/cost.

My questions are:
1) What does Compact and Repair actually do?
2) Can Access Queries be moved to SQL Server Views and be linked?
3) What can I do about Access Modules and Macros? Can they be moved to SQL Server somehow easily?
4) What other concerns should I have?

Also if any of you fine people have done this sort of thing in the past please share your stories :)

View 13 Replies View Related

SQL Server Security - Questions

Sep 25, 2006

I have created logins and user accounts in SQL Server.
How come, when I open SQL Server, it did not prompt for passwords ?
How can I make it to do so ?


********************************************
*** Thank you very much in advance, security gurus ***
********************************************

View 2 Replies View Related

Deploying To Server And Other Questions...

Jul 13, 2007

Guys,
Let me first give you a little bit of background...

One of my goals for this year is to migrate all DTS packages to SSIS, those DTS packages are used across the company by different groups/users.

Since I'm still not that familiar with SSIS and like many here, was well used to the enterprise manager view (all DTS packages on 1 single place), I'm unsure on how to structure my SSIS packages in a way that I could break it down by group let's say.
The way that I'm doing right now is: I'm creating a solution for each group and creating the SSIS packages (.dtsx) relative to that group inside each solution, that's pretty easy. Now, the next thing that I'll have to figure out (and hope you guys can help) is how to deploy them structured this way and how to handle these packages to my end users. Basically, how do I handle "Group A" all of their SSIS packages? Will they have to open the package in debug mode on VS every time they need to execute a package?

Thoughts on this?

View 3 Replies View Related







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