| Author |
Topic  |
|
|
Nowy
Yak Posting Veteran
57 Posts |
Posted - 06/08/2007 : 04:45:08
|
Why doesn't work this?
SELECT * FROM dbo.Interpolate ( (SELECT TOP 1 C4, C5, C6, C7, C8, C9, C10, C11, C12 FROM Test)
)
I get the following errors: sg 116, Level 16, State 1, Line 30 Only one expression can be specified in the select list when the subquery is not introduced with EXISTS. Msg 313, Level 16, State 3, Line 30 An insufficient number of arguments were supplied for the procedure or function dbo.Interpolate.
|
|
|
harsh_athalye
Flowing Fount of Yak Knowledge
India
5509 Posts |
Posted - 06/08/2007 : 04:48:23
|
Table-valued parameters for procedure/function are not supported in SQL 2000/2005.
Harsh Athalye India. "The IMPOSSIBLE is often UNTRIED" |
 |
|
|
khtan
In (Som, Ni, Yak)
Singapore
16769 Posts |
Posted - 06/08/2007 : 04:53:13
|
what are you trying to do ? this ?
SELECT * FROM
(SELECT TOP 1 C4, C5, C6, C7, C8, C9, C10, C11, C12 FROM Test ORDER BY C4) AS Interpolate
KH
|
 |
|
|
Nowy
Yak Posting Veteran
57 Posts |
Posted - 06/08/2007 : 05:00:13
|
| I want to get te params for the function "Interpolate" with an "Select" query |
 |
|
|
spirit1
Cybernetic Yak Master
Slovenia
11741 Posts |
Posted - 06/08/2007 : 05:50:39
|
-- declare variables
SELECT TOP 1 @c4 = C4, @c5 = C5, @c6 = C6, @c7 = C7, @c8 = C8, @c9 = C9, @c10 = C10, @c11 = C11, @c12 = C12 FROM Test
SELECT * FROM dbo.Interpolate ( @c4, ... , @12 )
_______________________________________________ Causing trouble since 1980 blog: http://weblogs.sqlteam.com/mladenp |
 |
|
|
harsh_athalye
Flowing Fount of Yak Knowledge
India
5509 Posts |
Posted - 06/08/2007 : 05:54:54
|
Very elegant! 
Harsh Athalye India. "The IMPOSSIBLE is often UNTRIED" |
 |
|
| |
Topic  |
|
|
|