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 |
|
Carat
Yak Posting Veteran
92 Posts |
Posted - 2009-09-25 : 13:06:59
|
| I have to make a mapping between account numbers from one system to another. The difficulty is that I have 8 parameters to do the mapping. Its actually too complex to explicate in here so I want to put an Excel in here with the mapping that I got from the management. Can this be done? |
|
|
Buzzard724
Yak Posting Veteran
66 Posts |
Posted - 2009-09-25 : 13:46:27
|
| not an expert on this or the forum capabilities but I guess you could import your excel into a table (or two) and then script the table as 'create to' and then 'insert to'? And then post the scripts to the forum |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-09-25 : 13:59:32
|
| dont export entire data. just post 5 or 10 rows to give us an idea. then somebody will help you out with query |
 |
|
|
Carat
Yak Posting Veteran
92 Posts |
Posted - 2009-09-29 : 10:28:29
|
| Ok I will show you a few records so you can see.AccountNumber LineType Destination Branch Debet AccountNumberXX[252.1] [I] [blanc] [blanc] [x] [291002020][421.41] [blanc] [blanc] [blanc] [blanc] [291002020][620.111.1] [E] [O] [1 or U] [blanc] [312040210][620.111.1] [E] [NOT O] [U or X] [blanc] [312040220][620.111.21] [E] [I or J] [1] [blanc] [612040420]So I have 5 parameters (AccountNumber, LineType, Destination, Branch, Debet) to get to AccountNumberXX.- 'Blanc' means that whatever value is filled its ok.- For the LineType I have 6 different possibilities (-, I, D, S, E, V)- For the Branch I have 16 different possibilities -, X, P, B, O, ...)- For the Destination I have 6 different possibilities (-, 1, 3, 6, U, X)How can I achieve the mapping between these parameters to get AccountNumberXX? I tried to write a function where I use dynamic SQL to check the parameters. So when a parameter is not 'blanc' than I will use it. But dynamic sql doesn't work in a function.Thanks. |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-09-29 : 13:03:44
|
| on what basis you decide how to assume a value from among possibilities? |
 |
|
|
|
|
|
|
|