The
create sql view may be stepping on your cursor of table_names (i.e., closing the cursor. you might try adding a Select 0 command on the line before the
command. You should also pass a 3rd parameter in the SQLTables() function which would be the name of the cursor to place the results in.
>Hi!
>
>I have a program that locks up my machine.
>
>I have attached it, I would like any and all advice I can get on it!
>
>I will do about 5-10 tables, depending on what all I change.
>
>I thought it might be a timeing problem, that's the reason for the wait window timeout 5
>
>>close all
>create database vistar_views
>create connection vistar datasource vipsw userid "dba" password "sql"
>nHandle = sqlconnect('vistar')
>x=SQLTABLES(nHandle, 'table')
>go bottom
>GO TOP
>SCAN
> MTABLE = ALLTRIM(TABLE_NAME)
> ? mtable, time()
> create sql view &mtable remote connection vistar as select * from &mtable
> select 2
> use &mtable
> go bottom
> ?? reccount(), time()
> wait window 'pausing for 5 seconds' timeout 5
> use
> select 1
>endscan
>
Mark McCasland
Midlothian, TX USA