Поделиться через


CDaoRecordset::GetSQL

Call this member function to get the SQL statement that was used to select the recordset's records when it was opened.

CString GetSQL( ) const;

Возвращаемое значение

A CString that contains the SQL statement.

Заметки

This will generally be a SQL SELECT statement.

The string returned by GetSQL is typically different from any string you may have passed to the recordset in the lpszSQL parameter to the Open member function. This is because the recordset constructs a full SQL statement based on what you passed to Open, what you specified with ClassWizard, and what you may have specified in the m_strFilter and m_strSort data members.

ПримечаниеПримечание.

Call this member function only after calling Open.

For related information, see the topic "SQL Property" in DAO Help.

Требования

Header: afxdao.h

См. также

Основные понятия

CDaoRecordset Class

CDaoRecordset Members

Hierarchy Chart

CDaoRecordset::GetDefaultSQL

CDaoRecordset::GetDefaultDBName

CDaoRecordset::GetName

CDaoRecordset::GetType