Click here to Skip to main content
15,912,021 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi sir,
I'm Arvind - I'm using SQL server 2005, I have problem in data base.
I have one store procedure and two data base object impact and impact 2, when we execute the store procedure in side the impact this is working but when we execute same store procedure inside the impact2 this is not working.

plz give me solution and which type error is occurring
Thanks & Regards
Arvind

[edit]Spelling, capitalization and punctuation only - OriginalGriff[/edit]
Posted
Updated 1-Jul-11 22:40pm
v2
Comments
OriginalGriff 2-Jul-11 4:38am    
We would need more information: what are the objects impact and impact2? Tables? If so, are they the same?
What are your stored procedures?
Use the "Improve question" widget to edit your question and provide better information.
RaviRanjanKr 2-Jul-11 6:47am    
Please be more specific while asking question. we need complete information about any question before answering it.
Arvind_singh 2-Jul-11 6:55am    
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO
ALTER Proc [dbo].[Sp_GetCompanyAddressNew]
@ContactTypeId as numeric(9)
as
begin
select distinct isnull(convert(varchar,Address1),'')+' '+isnull(convert(varchar,Address2),'')+' '+isnull(convert(varchar,Address3),'')+'*'
+isnull(convert(varchar,city.Name),'')+'-'+convert(varchar,PinCode)+'*'
+isnull(convert(varchar,state.Name),'')+','+convert(varchar,Country.Name) as address
from TblsubCompanyAddress SVA
Left outer join TblAddressBook City on SVA.City=city.AddressID
Left outer join TblAddressBook State on SVA.State=state.AddressID
Left outer join TblAddressBook Country on SVA.Country=Country.AddressID
where SVA.AddTypeId= @ContactTypeId
end
This is store procedure in in two database object Impact and Impact2 when we run this inside the impact this is working but when we run inside Impact2 this is not working this is return null values but both database table is same ......
Please give me solution

1 solution

Obviously there are differences between your two databases. Read the error messages, look at the tables and work out why one has different schema or data to the other.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900