Setting and Retrieving Data (转)

本文介绍了如何通过调用SetData方法设置元数据库中的数据,并使用GetData或EnumData方法进行数据检索。文中详细解释了METADATA_RECORD结构的作用及其实现方式,包括数据的安全存储和从元数据库中获取多个数据条目的方法。
Setting and Retrieving Data (转)[@more@]Platform SDK: Inte .NET Information Services 5.1

Setting and Retrieving Data

You can set data in the metabase by calling the SetData method. This method takes as one of its parameters a METADATA_RECORD structure, which contains information about the data (its identifier, attributes, user type, data type, a pointer to the data, and so on). By setting values for the members of the METADATA_RECORD structure when it is passed as an input parameter to the SetData method, you can specify the type of and storage method for the data. For example, you can specify that the data be stored in a secure manner by setting the METADATA_SECURE flag in the structure's dwMDAttributes member.

In addition to specifying the data to be retrieved, the METADATA_RECORD structure is also used to receive data from the metabase. When you call the GetData or EnumData methods, you pass in a pointer to a METADATA_RECORD structure to specify the data to be retrieved, and to receive the data. Your program must allocate the buffer into which the data will be retrieved, and pass a pointer to it in the pbMDData member of the METADATA_RECORD structure.

The GetAllData method retrieves multiple data entries from a key. In this case, you can use parameters of the GetAllData method to specify the data to be retrieved, and provide a buffer where the method returns an array of METADATA_GETALL_RECORD structures.

msdn.a%20href=microsoft.com/library/en-us/iisref/html/psdk/ ASP/tiny.gif" width=1> PlatfoRM SDK Release: Janurary 2002

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/10752043/viewspace-991043/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/10752043/viewspace-991043/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值