Thanks Ian
It's exactly what I have been trying to do, but my SQLEXEC always returns -1. My connection is OK, and my CREATE TABLE works fine outside SQLEXEC. This is just strange.......
>lnHandle = SQLCONNECT( 'MyConn', 'sa', 'password')
>
>lnResult = SQLEXEC( lnHandle, 'CREATE TABLE MyTable (....)')
>
>If you want a temporary file (one that gets automatically deleted when the connection is lost), add a # to the fornt of the name of the table
>
>HTH
Benn Kjaer
MS Certified Professional - Visual Foxpro
"There is something rotten in the state of Denmark"
"Why make user-friendly programs, when there aren’t any friendly users :o)"