If what you want to do can be expressed in a stored procedure, there is another option.
You can do a CREATE EXISTING TABLE and point it at a stored procedure. If you go to the Sybase ASE doc, you will find further information on the details and syntax.
The neat part is that you can pass arguments to the stored procedure during a query to the proxy table (what you really get from a CREATE EXISTING TABLE statement). There is a syntax for putting the arguments in the WHERE clause of the SELECT.
ASE 15.0.2 is supposed to have inline T-SQL scalar functions and 15.0.3 will have T-SQL table functions (thanks for the infor BRET). Also, ASE 15 includes the JAVA extension for free instead of making you pay for a license.
The final idea, though it does not really work in-line as I suspect you need/want, is an XP_SERVER. YOu can create C or C++ functions that get linked to the XP_SERVER and can be called via CIS (Component Integration Services) just like any other remote procedure call. If you have some nasty text manipulation or math that you don't want to try and do in T-SQL, and XP_SERVER gives you another option.
Can you tell us a bit more about the problem you are trying to solve? There may be some other options....
Regards,
Bill
Main Topics
Browse All Topics





by: knel1234Posted on 2007-02-01 at 07:39:36ID: 18444880
ganney,
tml
Are you running an ASE 12.0 or newer?
Do you have a JAVA license for your ASE?
Try here. This is Rob Verschnoor's site. Independent consultant that works for Sybase now.
Good website
This is the specific link
http://www.sypron.nl/udf.h
If you dont have a JAVA license or a 12.0+ ASE, there are other options to explore
cheers
knel