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 |
|
werhardt
Constraint Violating Yak Guru
270 Posts |
Posted - 2009-04-21 : 13:39:45
|
| I am moving my view that I created to a different database so I had to add this to my tables "Impact_prod." everything was working fine,except for my one view. I think I know where the problem is,but I am not sure how to fix it because I keep getting errors. I think what is giving me the error is this last line...INNER JOIN Impact_prod.dbo.clms clms ON clms.clms_id = clm.clm_id1Because it keeps saying Invalid object name 'dbo.clm'.FROM Impact_prod.dbo.clm clm Join Impact_prod.dbo.cli cli ON clm.clm_clir = cli.cli_id1 JOIN Impact_prod.dbo.clip clip ON cli.cli_id1 = clip.clip_id1 JOIN Impact_prod.dbo.clio clio ON cli.cli_id1 = clio.clio_id1 INNER JOIN Impact_prod.dbo.clms clms ON clms.clms_id = clm.clm_id1 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2009-04-21 : 13:44:27
|
| What do you have in the select statement?I doubt if it's the last line that causes the problem.Does Impact_prod.dbo.clm exist and can your login access it?try select top 1 * from Impact_prod.dbo.clm==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
|
werhardt
Constraint Violating Yak Guru
270 Posts |
Posted - 2009-04-21 : 13:47:09
|
Yes Impact_prod.dbo.clm does exist.In my select statement I do have some fields that sayclm. infront of them. See below.SELECT Distinct--clms_sku,--clms_line,--clm_prod,clio_type,clm.clm_id1, clm.clm_rcvd, CLM_DOUT,clm_wkpct, clm.clm_1a,clm.clm_12a, clm.clm_12b, clm.clm_55d, clm.clm_clir, clm.clm_65a, clm.clm_medb2, clm.clm_tchg, clm.clm_base,clm.clm_stades,quote: Originally posted by nr What do you have in the select statement?I doubt if it's the last line that causes the problem.Does Impact_prod.dbo.clm exist and can your login access it?try select top 1 * from Impact_prod.dbo.clm==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy.
|
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2009-04-21 : 17:04:25
|
| Is that the complete view?try using it viaselect top 1 * from viewname.also try copying the view into a query window and running it as a derived table.==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
|
|
|
|
|
|