![]() | |
![]() |
| | Thread Tools | Display Modes |
#11
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#12
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#13
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#14
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#15
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#16
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
#17
| |||
| |||
|
|
Jay, It is telling you that your subselects are getting more than 1 row back. So, a couple of possibilities are: 1. The join and filter on the subselect are not as specific as they should be. That may mean investigating the data to determine what is being overlooked. 2. Yes, multiple rows are being returned in some instances, but it does not matter to you since you just want a single Provider_Key. (Perhaps you even know that the multiple Provider_Key values are identical.) In that case, use an aggregate to enforce returning a single row. For example: UPDATE dbo.FEIProviderStatus SET ProviderKey = (SELECT MAX(Provider.Provider_Key) -- MAX enforces a single value FROM dbo.Provider WHERE Provider.Datasource_ID = FEIProviderStatus.DatasourceID AND Provider.Provider_key <> 8602) RLF I received the following message from a DTS package that fails. 'Subquery returned more than 1 value. This is not permitted when the subquery [quoted text clipped - 14 lines] Jay |
![]() |
| Thread Tools | |
| Display Modes | |
| |