RE: Index in Table .... request for explanation
"Mike Ayers" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <83E753BE7B6A324ABB336245BAF1DAAC0A893099@mailserver.metatv-ds.metatv.com> |
> From: M. Zeeshan - IMS [mailto:[email protected]] > Sent: Thursday, January 29, 2009 1:24 AM > I am still uncomfortable with such way of indexing, An oddly common sentiment, but if the notation was peerTable[1, "sh-client"], would you feel so uncomfortable? > 1. Do we have to use such index like "sh-client" for each row > entry in the table. Tables must be indexed, just like in a database. You can (and many do) make your indexes as integers and make the group name a row object. You'd then need to add a semantic restriction on name uniqueness if you still wanted such. > 2. we do this with the help of netsnmp_table_row_add_index(), > how this has to be done if we enter data into the table > through an automated utility or sort of software remotly, > then will the index for each row is necessary.. how will it > be used fot getting the data as well. You are programming the subagent to store data in a table. SNMP operations will access that data. > 3. when i generated code using mib2c with > "mib2c.create-dataset.conf" file, then the indexing was done > with the function "netsnmp_table_set_add_indexes()", while > the example in data_set.c uses the function > "netsnmp_table_row_add_index()" a bit earlier in the code, > whats the difference between these two functions. I don't know, but if I had to guess, I'd say that one handles a single index, and the other handles multiple indices. HTH, Mike ------------------------------------------------------------------------------ This SF.net email is sponsored by: SourcForge Community SourceForge wants to tell your story. http://p.sf.net/sfu/sf-spreadtheword _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users