I need to create an SQL that will show amount of sales for specific agencies and what percentage of all sales this number represents Create table...
I am trying to write an SQL statement to update a large table (6 million rows) from a smaller one (3000 rows) TABLE A booking int...
I am using the OPENQUERY to read data from a remote database and insert into SQL Server. The procedure can be quit slow, is there a database...
I have a table (3.8 million rows) that has 2 indexes defined (product, departure) but when I use a select statement specifying only 1 or other index,...
I am working on a data warehouse system which requires inventry to be reported on a monthly basis. The main system uses inventory on a daily basis....
I am currently using the SQL database as the database for Bi reports and graphs. Data is extracted from a database on an HP_UX system and put into...
I have been running the same overnight job for the past five months without a problem and now I am getting Server: Msg 7399, Level 16, State 1, Line...
I have created a user functions which returns a table. The function has one parameter which is the date. Is it possible to create a view where I can...
I have a table which contains all of the booking information. I need to be able to extract information from this table IE # passengers, sales, etc...
I have two tables. One with booking number,destination,departure date and the other with booking and passenger name I need to create a list of...
The data is stored as follows; One record per booking and the record contains agent X16, amt Money, month_year x6, branch X2 I...
I am unable to create an ODBC connect from my Windows XP machine to the SQL server on a windows 2000 machine. What am I doing wrong?
I am developing a datawarehouse in MSSQL, populating it with data from an Eloquence database (replacement of IMAGE 3000) on an HP_UX machine. Is it...
Is it possible to select the MAX of a SUM. I need to find the Name of a hotel which sold the most nights in a season where the nigths sold is stored...
I need to retreive data from the sales table for two different time periods. I am currently doing this with a view Sales_Table ------------...
I have the following statement<br /><br />select a.dest,case when sum(a.nights) <> 0 then<br /> ((sum(a.sold)/sum(a.nights))*100) else...
I want to update 2 columns in one table with aggregate values from 2 columns in another table. Is there a way to do this in one update statement...
Separate names with a comma.