>Hi Mark,
>
>Is this a long the lines of what you are saying?
>
>* These 2 lines at the startup?
>CREATE CONNECTION myconnect DATASOURCE "XXXX" USERID "YYYY" PASSWORD "ZZZZ"
>nhandle = SQLCONNECT('myconnect')
>
>* This when I need the info?
>SQLEXEC(nhandle, SELECT invc_ln.invc_ln_no, invc_ln.invc_no FROM PROD.invc_ln invc_ln WHERE invc_ln.invc_no IN (&invc_nos), 'invc_ln_cursor')
>
> I hope I got your meaning.
>Thanks again
You are definitely on the right track. You would not need to create the connection if it already exists in the main DBC and that is the DB currently selected. You only need to create it if you still create and open a temporary DBC for each user.
What happens if the user accidentally [or intentionally] launches a second instance of your application?
Mark McCasland
Midlothian, TX USA