>>Do you know why I'm getting errors on these two lines
>>
>> SELECT [name] from [sysdiagrams] WHERE [name] LIKE '%<script%'
>> RAISERROR('Error in table sysdiagrams in column name ',16,1)
>>
>
>Maybe because you didn't have a database diagram defined in that DB?
No, it looks like all END statements got out of place. If I would not have this table, I would have different error.
Also I think we need to add
IF OBJECT_ID([<<alltrim(Table_Name)>>]) IS NOT NULL
statement in my VFP program
If it's not broken, fix it until it is.
My Blog