how to connect to sql express 2005/2018/2014 ?
how to connect to sql express 2005/2018/2014 ?
please post example. thx
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
Re: how to connect to sql express 2005/2018/2014 ?
If you don't have one, install Microsoft ODBC driver.sartic wrote:please post example. thx
https://www.microsoft.com/en-us/downloa ... x?id=53339
After that, create a User DSN via Control Panel's Administrative Tool Data Sources (ODBC) (or you can even do it directly via PB, see this great example) and simply use PB's database ODBC instructions from documentation.
Code: Select all
UseODBCDatabase()
;Makeconnection("ODBC Driver 13 for SQL Server", "Dsn=myDSNName;Server=tcp:myAzureName.database.windows.net,1433;Database=myDbNAME;Encrypt=yes;TrustServerCertificate=no;") ;Optional
Define.s dbName = "myDSNName", dbUser = "yourDBName", dbPass = "yourDBPass"
Define.i dbHandle
dbHandle = OpenDatabase(#PB_Any, dbName, dbUser, dbPass, #PB_Database_ODBC)
If dbHandle
;Do your SQL stuff as you normaly would...
EndIf
Re: how to connect to sql express 2005/2018/2014 ?
Is the database local or remote ?
Re: how to connect to sql express 2005/2018/2014 ?
it is local.i will explore it this weekend if i solve problem with crush in closewindow()
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
Re: how to connect to sql express 2005/2018/2014 ?
Texas Instruments TI-99/4A Home Computer: the first home computer with a 16bit processor, crammed into an 8bit architecture. Great hardware - Poor design - Wonderful BASIC engine. And it could talk too! Please visit my YouTube Channel