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.
Author |
Topic |
jje
Starting Member
4 Posts |
Posted - 2008-09-21 : 05:04:22
|
Hi,I have a small business server 2003 premium running (included SQL)On this SBS 2003 I have SAP busines one running using the SQL server.My problem is, that I, by mistake and don't ask me how, have inserted an addres in the businespartner code field, which is causing troble when ever I want to make a query from businespartners table "OCRD" Item "Cardcode"Is it possible to thange the value of this businespartners cardcode?I have tryed with "MS SQL Server Find and Replace Software" but it only changes all other values and not, what I call the primary key.It also seems that some refferences to this businespartne disapears.Can any one help me solve this problem?Kind regardsJan Jensen |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-09-21 : 05:09:53
|
Is Cardcode the primary key of table? is it an identity column? |
|
|
jje
Starting Member
4 Posts |
Posted - 2008-09-21 : 06:46:30
|
quote: Originally posted by visakh16 Is Cardcode the primary key of table? is it an identity column?
Unfortunally I am not a pro!As far as I can see, is it a primary key!I am not sure how i can see if it is an identity column, bu there is no mark or sign in the column "ID" on the table proberties! |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-09-21 : 07:17:23
|
quote: Originally posted by jje
quote: Originally posted by visakh16 Is Cardcode the primary key of table? is it an identity column?
Unfortunally I am not a pro!As far as I can see, is it a primary key!I am not sure how i can see if it is an identity column, bu there is no mark or sign in the column "ID" on the table proberties!
Take the table definition and see. the below will give you table definitionsp_help yourtablename |
|
|
jje
Starting Member
4 Posts |
Posted - 2008-09-21 : 07:43:54
|
This is the answer I get from SQL query analyzerNo identity column defined. NULL NULL NULL |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-09-21 : 07:58:43
|
run this and see whatt other tables are dependent on this tablesp_depends yourtablename |
|
|
jje
Starting Member
4 Posts |
Posted - 2008-09-21 : 12:31:03
|
This is the answer on sp_dependsbwuser.SBO_CUSTOMER_ATTR viewbwuser.SBO_CUSTOMER_TEXT viewbwuser.SBO_VENDOR_ATTR viewbwuser.SBO_VENDOR_TEXT viewdbo.TmSp_RebuildMatchHistory stored proceduredbo.TmSp_SetBalanceByJdt stored proceduredbo.TmSp_SetVendorDeductPercent stored procedure |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-09-21 : 13:04:32
|
quote: Originally posted by jje This is the answer on sp_dependsbwuser.SBO_CUSTOMER_ATTR viewbwuser.SBO_CUSTOMER_TEXT viewbwuser.SBO_VENDOR_ATTR viewbwuser.SBO_VENDOR_TEXT viewdbo.TmSp_RebuildMatchHistory stored proceduredbo.TmSp_SetBalanceByJdt stored proceduredbo.TmSp_SetVendorDeductPercent stored procedure
so i guess there's no other table dependent on your table. so you could update value using simple update. just useUPDATE OCRDSET Cardcode=newvalueWHERE Cardcode=yourwrongvalue |
|
|
|
|
|