Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

adding new objects

Status
Not open for further replies.

Wladymyr

Technical User
Apr 3, 2002
1
US
Hi everybody,

Does anybody knows how to add an object using a perl script or a shell script or even a C program?

tia,

wladymyr Prado
 
You can add objects directly into the database using whatever will update an Oracle database. We do it at work all of the time.

Even though we do it, I don't agree with it or reccomend it to you. It's a fraught process that I'll bet took a long time to get right. And if HP do a mega upgrade that changes half the tables in the database it will take us "a while" to upgrade... Mike
"Experience is the comb that Nature gives us after we are bald."

Is that a haiku?
I never could get the hang
of writing those things.
 
I have done via several HP Openview C language APIs (from the SDK)including OVwDbCreateObject and OVwCreateSymbol.
I create a new menu item on HP Openview item (using a registartion file). The menu item action was mapped to "Adding an object" C callback routine. In the routine,
1. I created a field binding by getting the field id => OVwDbFieldNameToFieldId(<name of a HPOV field >), then allocated memory via malloc for OVwFieldBinding structure. finally stored field_id, field value, type, etc. into field binding structure.
2. Created object using field binding structure as input to OVxDbCreateObject.
3. Create symbol tied to the object using OVwCreateSymbol.

The Windows Developers Guide gives you snippets of code for using this.

Hope this helps.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top