Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 stored procedure

Author  Topic 

rajasekhar857
Constraint Violating Yak Guru

396 Posts

Posted - 2010-06-17 : 05:23:51
Hi i am having two tables gendermapping and usersmapping where service_provider column is newly added for them.

EMRSERVICEPROVIDER is a table where we need to update the above column where group_id and service_provider are common in both tables.Shouls update service_provider in above columns with group_id specific.

how to give a procedure for this.


webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2010-06-17 : 05:29:11
Don't tell us too much because maybe we can help too fast.
Don't give table structure, example data and wanted result because then there is no challenge for us.
I like it very much to join tables without knowing anything about the relations.



No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2010-06-17 : 06:16:31
quote:
Originally posted by webfred

Don't tell us too much because maybe we can help too fast.
Don't give table structure, example data and wanted result because then there is no challenge for us.
I like it very much to join tables without knowing anything about the relations.



No, you're never too old to Yak'n'Roll if you're too young to die.


That is the real challenge when you want to answer to the questions asked by this OP

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

rajasekhar857
Constraint Violating Yak Guru

396 Posts

Posted - 2010-06-17 : 06:32:12
Hi sorry for my post,
my requirement is like whenever
SELECT SERVICE_PROVIDER_ID FROM EMRSERVICEPROVIDER WHERE GROUP_ID = 1501 AND PROVIDER_TYPE='BILLING'
AND STATUS =1;

it should update EMRSERVICEPROVIDER table column SERVICE_PROVIDER_ID value into newly added table column values .

for that i have n no of group_ids.for all group_id specific i need to update SERVICE_PROVIDER_ID newly added column
using above select condition.
Go to Top of Page
   

- Advertisement -