The output of sql commands, visible to users who interactively run SQL commands from SQL Server Management, is different from the output returned from an ADO command or an ADO query object.
USE [DBNAME]
BACKUP DATABASE [DBNAME] TO
DISK = 'C:\SqlBackup\Backup.mdf'
A successful completion result is as follows:
Processed 465200 pages for database 'DBNAME', file 'filename' on file 2.
Processed 2 pages for database 'DBNAME', file 'filename_log' on file 2.
BACKUP DATABASE successfully processed 465202 pages in 90.595 seconds (40.116 MB/sec).
When I execute either TADOCommand or TADOQuery with CommandText or SQL as above, I do not get this output. How to read this "secondary result" from an SQL command? I hope that perhaps through some raw ADO operations, I could execute the command and get the information above for success, as well as any errors while performing Sql backup.
. , , , Delphi TADOCommand TADOConnection:
- TADOCommand TADOConnection.
- .
- .
, , , " dbname" , , "use dbname", , . , ADO, , , . , , Com Anyways VCL . , - , , "SQL Backup Delphi" .