Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Pass-through character limits?
Message
From
08/12/1998 11:45:36
 
 
To
08/12/1998 11:44:39
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00164772
Message ID:
00165145
Views:
11
Cool! Got that, Don?


>CREATE PROCEDURE AA AS
>Declare @MyString Char(30)
>Select @MyString="Select * From TStation"
>EXECUTE ('CREATE PROCEDURE AAA AS'+@MyString)
>
>>Really?? Could you post the example here for Don? Cool....
>>
>>>John, you know what? My friend just created stored procedure with text concatenation from variables on-fly (it's SQL Server 6.0).
>>>
>>>>
>>>>Funny, I was just researching the script approach. I'm my Using SQL Server 6.5 book, they mention a \scripts subdirectory for .IDC scripts (maybe .SQL too?) so look at the SQLServer dir tree and maybe it's there?
>>>>
>>>>>I don't think so... But here is another approach we are now considering...
>>>>>
>>>>>Use VFP as the front end to create a .SQL script file with the desired statement, then have a single procedure on the back-end with one parameter... the name of the .SQL script. The stored procedure will do nothing but
>>>>>
>>>>>DO .SQL script (which is the entire query)
>>>>>ERASE .SQL script
>>>>>
>>>>>This seams like an easier approach since VFP has all the low-level editing where we can create the file and assign the filename easier... How would I go about handling the file pathing and file name information as the parameter?
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>>Don, could you consider two-record interim table, i.e. you put actual values in two or more records there and then call stored procedure which will operate with these values, i.e. no macros substitution/variable needed.
>>>>>>
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Previous
Reply
Map
View

Click here to load this message in the networking platform