Explaining a SQL query
I have a query for finding the fith lowest salary in a SQL database, and I am not able to understand how this query will be processed internally. It is: select * from emp a where 5= (select count(distinct sal) from emp where a.sal>=b.sal) Can you explain this to me?

Answer Question   |  December 29, 2008  7:54 PM
SQL Server, SQL Server Query
2,585 pts.

Storing images in SQL Server 2005 and retrieving them from VB.NET
How can I store images in SQL Server 2005 and retrieve them from VB.NET?

Answer Question   |  May 18, 2012  7:52 PM
SQL Server 2005, VB.NET
2,585 pts.

Calling an Oracle stored procedure in SQL Server
I need to call an Oracle stored procedure from SQL Server. The stored procedure is written in ANSI SQL. ORCL is my linked server. I am calling ORCL.USER.PROCEDURE P1, P2, P3 and I am getting this error: Could not execute procedure ‘PROCEDURE_NAME’ on remote server ‘ORCL’. [OLE/DB provider returned message: One or more errors occurred [...]

Answer Question   |  December 29, 2008  7:50 PM
ANSI norm, ANSI SQL, Oracle stored procedures, SQL Server stored procedures
2,585 pts.

Indexes and abstracts in SQL Server
In regards to a SQL Server, what is an index? Also, what is an abstract, and could you please explain the types of both of these items?

Answer Question   |  December 30, 2008  7:45 PM
Abstracts, Indexes, SQL Server
2,585 pts.

Accessing the Northwind database in SQL Server 2005
In SQL Server 2005, I am not able to access the Northwind database. Some people have said that it is built into the SQL Server, but I can’t access it. How would I do so?

Answer Question   |  December 30, 2008  7:44 PM
Northwind sample database, SQL Server 2005
2,585 pts.

Migrating SQL Server 2005 back to SQL Server 2000
How would I go about migrating SQL Server 2005 back to SQL Server 2000?

Answer Question   |  December 31, 2008  7:42 PM
SQL Server 2000, SQL Server 2005, SQL Server migration
2,585 pts.

eMail SQL Server Logs
I’m new to SQL Server Management Studio…… Is it possible to set it up to eMail Server Logs to myself? Thanks!

Answer Question   |  December 23, 2008  5:41 PM
SQL Server Management Studio, SQL Server Management Studio Logs
asked by:
5 pts.

How to write Bcp command to insert data in to a table
Hi, I have a file which contains the data 2:23:3#1:2:4#2:3:5 i have to insert the data in to the table in multiple rows from a single file as #–indicates to be inserted in next row : –indicates next column column1 column2 column3 2 23 3 1 2 4 2 3 5 I need to use [...]

Answer Question   |  January 8, 2009  2:34 PM
BCP Utility, SQL, SQL 2005
asked by:
GIG
240 pts.

Changing databases at run time in SQL Server 2005
I am using Crystal Reports 8.5, Visual Basic 6 and SQL Server 2005. In my server, I have two databases named Eng_School_Database and Guj_School_Database with the same structured tables. I want to change the databases at run time so that the report should contain the data of desired medium. I have tried the following code: [...]

Answer Question   |  January 9, 2009  3:23 PM
Crystal Reports 8.5, SQL Server 2005, Visual Basic 6
2,585 pts.

Deploying SQL Server Express to host databases off a mapped drive
I am trying to deploy SQL Server Express to be able to host a database off a mapped drive. In an open lab environment, I can get it to open and run a database off a mapped shared drive on a Windows 2003 server. However, when I take it to a client and their area [...]

Answer Question   |  December 31, 2008  3:18 PM
Mapped drives, SQL Server databases, SQL Server Express, Windows Server 2003
2,585 pts.

Script to restore database permissions during a migration to SQL Server 2005
We are in the process of migrating from SQL Server 2000 to SQL Server 2005, and I’m searching for a script that can transfer and restore the database permissions of all accounts from SQL Server 2000 to SQL Server 2005. I used sp_help_revlog to restore the logins, but I still have to restore the database [...]

Answer Question   |  December 24, 2008  3:13 PM
Database permissions, SQL Server 2000 to SQL Server 2005 migration, SQL Server 2005, SQL Server Database Permissions, SQL Server databases
2,585 pts.

stored procedure in delphi with oracle
how to match the datatype of the field that is in database and the datatype of the variable that holds the value of the returned value from database using stored procedure.

Answer Question   |  December 29, 2008  1:50 PM
Delphi, Delphi 5, Oracle, Oracle stored procedures, Stored Procedure variables
asked by:
VPL
95 pts.

SQL Writer error message – SQLDUMPER library failed
error sql writer – sql dumper liabrary failed initialization install corrupt or tamper with

Answer Question   |  June 22, 2010  6:09 PM
Error SQL4304N, SQL, SQL writer, SQL Writer error messages, SQLDUMPER library failed initialization
asked by:
5 pts.

Index Strategy for existing SQL Server 2005 project
Hi All I Newly joined with new Project,My Boss told me that Create Index strategy document which in excisting Project. I don’t where to start. I prepared some documents which is basically saying about Index recomandation,When we have to creat Indexes,and so other stuff which is finding most used Indexes and Unused index on so….on. [...]

Answer Question   |  December 22, 2008  2:30 PM
Database index strategy, Index strategy, SQL Server 2005, SQL Server 2005 index strategy, SQL Server index strategy
asked by:
20 pts.

Moving data from one DB to another DB in SQL Server 2005
Hi all I got formula to calucalate Row_size of a table Row_Size = Fixed_Data_Size + Variable_Data_Size + Null_Bitmap + 4 Fixed_Data_Size = total byte size of all fixed-length columns Variable_Data_Size = 2 + (Num_Variable_Cols x 2) + Max_Var_Size Num_Variable_Cols = number of variable-length columns Max_Var_Size = maximum byte size of all variable-length columns Null_Bitmap = [...]

Answer Question   |  December 22, 2008  2:22 PM
Data migration, Max_Var_Size, SQL Server 2005, SQL Server 2005 migration, SQL Server migration
asked by:
20 pts.

Joining Tables in SQL Server
What is the difference between Outerjoin and Left outerjoin.

Answer Question   |  December 20, 2008  10:23 AM
JOIN statement, LEFT OUTER JOIN statement, OUTER JOIN statement, SQL Server development, SQL Server Query, SQL statements
asked by:
15 pts.

Referencing a calculated column in a SQL clause
This is our SQL code:   Select addrid,addrkey,addrline1,addrline2,addrline3,addrcity,addrplace,addrzipcod,addrtype,addrphone,jobsconame,addrmc1, CASE month(getdate()) WHEN 1 THEN addrjan WHEN 2 THEN addrfeb WHEN 3 THEN addrmar WHEN 4 THEN addrapr WHEN 5 THEN addrmay WHEN 6 THEN addrjun WHEN 7 THEN addrjul WHEN 8 THEN addraug WHEN 9 THEN addrsep WHEN 10 THEN addroct WHEN 11 THEN addrnov WHEN [...]

Answer Question   |  April 19, 2013  7:46 PM
SQL Server, T-SQL
2,585 pts.

Assigning data distributions to SQL Server 2005 databases
In SQL Server 2005, we have two databases. We want the first one to store tables, and the second one to store views of the tables in the first one. We have achieved this if the tables and views are in the same database, but is there a way to do it with two?

Answer Question   |  December 20, 2008  7:44 PM
SQL Server 2005, SQL Server databases
2,585 pts.

Error when restoring a SQL Server 2005 database
Every time I restore one of my SQL Server 2005 databases to a point in time, my log shipping restore job fails on my secondary server. Any ideas on how to correct this?

Answer Question   |  December 20, 2008  7:41 PM
Log Shipping, SQL Server 2005, SQL Server database
2,585 pts.

Corrupting database in an VB.NET application in SQL Server 2005
I have a application in VB.NET with SQL Server 2005 Express Edition. In the last few days, the database is continuously corrupting. I repair it, but the problem continues. I revise my code, but I can’t find transactions errors that could produce the problems. Do you have any general ideas?

Answer Question   |  December 23, 2008  7:40 PM
SQL Server 2005, SQL Server database, VB.NET
2,585 pts.