Hello,
I have a VB Function that I'd like to run in SQL Server. Is that possible?
Thanks! 9 1587
Jozef (SP**********@telus.net) writes: I have a VB Function that I'd like to run in SQL Server. Is that possible?
In SQL 2000, only with quite some pain. If you make into an OLE object
you can.
In SQL 2005 you can implement stored procedures and functions in any
..Net languages. (Not VB6.)
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se
Books Online for SQL Server SP3 at http://www.microsoft.com/sql/techinf...2000/books.asp
Tell us what the function does. Maybe it is possible to do the same in
Transact SQL.
--
David Portas
SQL Server MVP
--
Hi David,
The function cycles through a string and modifies it, formatting characters
after a space or special character. I also have other functions that do
some encryption decryption and things like that.
Thanks!
"David Portas" <RE****************************@acm.org> wrote in message
news:AK********************@giganews.com... Tell us what the function does. Maybe it is possible to do the same in Transact SQL.
-- David Portas SQL Server MVP --
Jozef (SP**********@telus.net) writes: The function cycles through a string and modifies it, formatting characters after a space or special character. I also have other functions that do some encryption decryption and things like that.
Look up Functions/String funtiosn in the T-SQL reference. Admittedly,
string manipulation is not what T-SQL is best at, but there are some
possibilities.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se
Books Online for SQL Server SP3 at http://www.microsoft.com/sql/techinf...2000/books.asp
You can drive yourself nuts doing string manipulation in SQL; you are
far better off leaving string maniupulation to the business object or
presentation layer, rather than trying to bubble up from the bottom.
If you are looking to update your data, you can do that as well on a
higher level, rather than attempting to gnosh the data from below.
If you want to do this for an academic exercise, look at the CHARINDEX
and PATINDEX functions. And then drink heavily.
Stu
Stu (st**************@gmail.com) writes: You can drive yourself nuts doing string manipulation in SQL; you are far better off leaving string maniupulation to the business object or presentation layer, rather than trying to bubble up from the bottom.
Depends on what you want to do. Some things are easy to do in T-SQL. But
admittedly it easily becomes cluttered and complex, and some stuff is
about impossible.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se
Books Online for SQL Server SP3 at http://www.microsoft.com/sql/techinf...2000/books.asp
Formatting of results is best done client-side. However, if you want to
manipulate and store strings in the database then it maybe worthwhile
re-writing your functions in TSQL. Take a look at the range of string
functions in SQL Server Books Online.
..NET and the MS CryptoAPI should provide all the crypto functions you will
need. Although it can make sense to put encryption in the database, doing it
in the client or middle tier will serve most applications just as well or
even better.
--
David Portas
SQL Server MVP
--
I agree; I wish SQL had a RegEx function to easily search for patterns
and split it into smaller pieces. We have to maintain a syslog
database for our clients, and it would be nice if I could chop that up
into usable chunks on the fly, rather than through an import process.
But, c'est la vie.
Stu
Stu (st**************@gmail.com) writes: I agree; I wish SQL had a RegEx function to easily search for patterns and split it into smaller pieces. We have to maintain a syslog database for our clients, and it would be nice if I could chop that up into usable chunks on the fly, rather than through an import process.
Well in SQL2005 you can use the RegEx class in the CLR.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se
Books Online for SQL Server SP3 at http://www.microsoft.com/sql/techinf...2000/books.asp This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: lawrence |
last post by:
Suppose I create dynamic web pages with 3 functions (which call other
functions to make everything happen, but these 3 you might think of as
being the top layer):
registerSessions();...
|
by: Michael Schmitt |
last post by:
Hello.
What is the usual way for running functions in parallel on a
multiple-processor machine. Actually I want to run a single computationally
expensive function with different parameter sets....
|
by: Richard A. DeVenezia |
last post by:
I have a function that will update a divs innerHTML with the result of a
long running loop. I would like to update the div prior to running the loop
so the person knows it is doing something....
|
by: ThunderMusic |
last post by:
Hi,
How can I get if the Windows running is a server version?
Is there a property somewhere that can tell me if the Windows version is a
server edition (including server, advanced server, web...
|
by: Matthias H. |
last post by:
Hi guys,
Our team has a very strange problem. I hope anybody can help.
We have a class called webpage and all our aspx-pages bases on it. Then we
have a SYS.IO.File Class which have a...
|
by: Anonieko |
last post by:
Query: How to display progress bar for long running page
Answer:
Yet another solution. REFERENCE:
http://www.eggheadcafe.com/articles/20050108.asp
My only regret is that when click the...
|
by: plmanikandan |
last post by:
Hi,
I have written a win32 console application(exname1.exe) which runs for
ten minutes.I am calling this exname1.exe from another exe named
exname.exe using shellexecuteex.Now from exname.exe...
|
by: Phil Stanton |
last post by:
I have a number of queries which use code for the output of 1 or more
fields. For example
Address:GetAddress(AddressID, True, 60)
Address ID Points to an Address in a table - Address Line1, Line...
|
by: lmttag |
last post by:
Hello.
We're developing an ASP.NET 2.0 (C#) application and we're trying to
AJAX-enable it. We're having problem with a page not showing the page while
a long-running process is executing. So,...
|
by: BrianMiller |
last post by:
I have searched for an answer but have failed to come up with anything that seems to work.
I am trying to set up an Access 2003 database for home accounts. I want to create a running sum (a...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: Shællîpôpï 09 |
last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |