You'll need something like this ahead of creating the function: if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[MyFunction]') and xtype in (N'FN', N'IF', N'TF')) drop function [dbo].[MyFunction] GO
...add function here -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ailsom F. Heringer (Osklen) Sent: Monday, August 21, 2006 8:20 AM To: [EMAIL PROTECTED] Subject: Verify and create an Sqlserver function ??? Foxers, I have an SQLSERVER script that creates a function in the database. This script is correct and ready to be used. But how can I, using a VFP application, verify if this function isn´t already created and then run the script ? -- Aílsom F. Heringer [EMAIL PROTECTED] Skype: ailsom.osklen Analista de Sistemas ---------------------------------- Osklen Departamento de Informática Rio de Janeiro - RJ BRASIL http://www.osklen.com.br 55 21 22198971 [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

