CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 MSSQL 2000 FUNCTIONS

Print topic Send  topic

Author Message
taz
Posted: 01/13/2002, 3:41 AM

user defined function is the most important new feature of MS SQL 2000

however CC cant evaluate succefully an SQL statement that calls such a function

e.g. custom sql = select * from getDescription(id) : produces an error

while sql = select * from getDescription(12) works.

any workaround to this problem ?
Alex Alexapolsky
Posted: 01/14/2002, 1:24 AM

What kind of error does it produce ?
In design time or run time ?
Nicole
Posted: 01/14/2002, 3:03 AM

Hello,
in addition to Alex words:
what is it "id"?
what language pattern do you use?
taz
Posted: 01/14/2002, 5:33 AM

In general I would like the SQL string to use a function that returns a table and has the general form: functionName(@param)

the sql string should be something like select * from functionName(@param)

but i'm getting a design error unless a specified @param is used, e.g. select * from functionName(1).

I' ve figured out that if i use the specific one first i can builkd up the form and then switch to the general one since i m not getting any runtime errors, however this is not convininet coz the form elements become locked , available parameters are not shown then , the error messages pop up all the time, etc.

Is there a more convinient solution , other than editing the .asp files afrewards?

What should this SQL string look like regardless of the type of the @param?

PS i'm using ASP + templates
Nicole
Posted: 01/15/2002, 1:55 AM

Hello,
for esign time try to use sql like:
select * from getDescription(999)
with any value. This sql need for design time to select field names only. For real working site you should replace this temporary value in Open event. Use the code like:
sSQL = replace(sSQL, "getDescription(999)", "getDescription("& id &")")

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.