I'm making a PHP script for controlling my mssql databases. But I ran into a couple of problems.
The first problem is that I want to make a combobox out of all the databases in my microsoft SQL server. The following SQL syntax gives the results that I'm looking for, but I don't know how to place it into a combobox.
SELECT name from sys.databases where owner_sid != 0x01
My next problem is, that I have to run follwing SQL command:
RESTORE FILELISTONLY FROM DISK = 'C:\Databases\Breda\backup\Backup.BAK'
But I need to get the first column of every row, and place that in 2 variables, but I don't know how to do that.