共用方式為


2.2.1.6 QueryComparisonData

The QueryComparisonData structure is part of the representation of a query, as used in the ICatalogTableInfo::GetClientTableInfo (section 3.1.4.7.1), ICatalogTableRead::ReadTable (section 3.1.4.8.1), and ICatalogTableWrite::WriteTable (section 3.1.4.9.1) methods. It is always used along with a QueryCellArray (section 2.2.1.5) structure.

QueryComparisonData is a custom-marshaled type that is passed in a char* parameter. A QueryComparisonData is marshaled as an array of zero or more custom-marshaled comparison data values, each of which is associated with a QueryCell. Each non-null comparison data value MUST be marshaled in the same order as the QueryCell to which it is associated and according to the custom marshaling defined as follows for each of the supported types (a query with zero non-null comparison data values MUST be represented by a NULL pointer).


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

ComparisonData (variable)

...

ComparisonData (variable): A sequence of zero or more comparison data values, marshaled according to type.

Type

Custom marshaling

eDT_ULONG

Marshaled as a 32-bit, unsigned integer in little-endian byte order.

eDT_GUID

Marshaled as specified in [MS-DTYP], section 2.3.4.2.

eDT_BYTES

Marshaled as an array of bytes, padded with zeros to a multiple of 4 bytes.

eDT_LPWSTR

Marshaled as a null-terminated array of wchar_t in little-endian byte order, padded with zeros to a multiple of 4 bytes.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

ComparisonData 0 (variable)

ComparisonData 1 (variable)

...

ComparisonData m (variable)