Viewing 15 posts - 241 through 255 (of 455 total)
You can use the following syntax
SELECT a.*,b.*
FROM dbo.currentdbtable a
JOIN
secondb..tablename b ON b.somecolumn = a.somecolumn.
Please post your query, so that it would be more clear.
September 28, 2006 at 9:45 am
What Sriram has posted is for example for you to understand. You do the same practise of dumping your data to a table as you are currently doing and replace...
September 28, 2006 at 9:40 am
Try copying the expression of rowgroup and pasting in the row section. I donot have RS handy on this system to try and confirm.
September 28, 2006 at 9:29 am
Make sure you are not using any of the above authentication users (dbo, dbcreator or sysadmin) as mentioned by Mike in your connection string for the application.
September 28, 2006 at 9:26 am
Do you mean to say you must be able to enter Promotion code against each order in your report? I don't think its possible. Reporting only supports read only display...
September 28, 2006 at 8:58 am
Include IF EXISTS DROP, CREATE statement when you are creating your temp table inside the script, however you should not really get the error on PK violation as the scope...
September 28, 2006 at 8:49 am
The output will be returned as MonthName as part of the resultset, do you want it to be printed?
September 28, 2006 at 3:03 am
I believe the closing brace after group by Practitioner is missing, PractitionerGroup is the derived table and the syntax should work without any errors.
September 28, 2006 at 2:44 am
CREATE PROCEDURE MyProc
@Field VARCHAR(50)
AS
DECLARE @StrQry VARCHAR(1000)
SET @StrQry = 'SELECT ' + @Field + ' FROM Customers WHERE (City = ''Berlin'')'
EXEC (@StrQry)
GO
EXEC MyProc 'CustomerID'
GO
September 28, 2006 at 2:06 am
CREATE PROCEDURE MyProc
@Month VARCHAR(12)
AS
DECLARE @Qry VARCHAR(1000)
--SET @Month = 'July'
SET @Qry = 'SELECT CASE ' + @Month + ' WHEN 1 THEN ''ONE''
ELSE ''TWO'' END AS MonthName
FROM
LockDatabase
WHERE
CompanyID=''BM''
AND
...
September 28, 2006 at 1:51 am
Transaction boundaries are required when you are trying to do multiple inserts and based on the output of the first insert if you are doing a second insert and if...
September 28, 2006 at 1:44 am
First of all why do you Numeric as datatype when you are saving INT value, you can have it a BIT or SMALLINT and from your post I believe you...
September 28, 2006 at 1:39 am
What is the Datatype error you are getting?
SELECT CASE MonthName
WHEN
1
THEN
'One'
WHEN
2
THEN
'Two'
END As MonthName
FROM
LockDatabase
WHERE
CompanyID='BM'
AND
Finyear='2006-2007'
AND
MonthName = @Month
Hope this helps...
September 28, 2006 at 1:25 am
You mean to say, you save the LedgersID as Comma Separated values in the column or do you pass the comma separated values to SP through LedgersID. You are using...
September 27, 2006 at 6:05 am
select spid,
ecid,
status,
loginame=rtrim(loginame),
hostname,
dbname = case
when dbid = 0 then null
when dbid <> 0 then db_name(dbid)
end
, cmd
from master.dbo.sysprocesses
WHERE Status ='sleeping'
September 26, 2006 at 8:10 am
Viewing 15 posts - 241 through 255 (of 455 total)