I have a user defined function which is passed a numeric and then
returns another numeric (a range lookup).
When used in a view, this returns everything as expected.
I then try to limit the view by the returned value (select * from
myview where maxrange >= 5), but I get an error 'Converting nvarchar
Problem is, that I know it is numeric.
My question is - can I do select from a view on the result of a
function (I think YES).... my second problem is that if I do something
like (select * from myview where somecolumn=1234567 and myvalue >= 5)
this will work.
I can run this sucessfully on my development SQL Server 2000, but the
production database (which I created my scripts from the development
database) do not work. I am confused at the differences as the
databases should be identical.
Anyone got any ideas?