Variable length and types

All questions related to installations, configurations and maintenance of Advanced Host Monitor (including additional tools such as RMA for Windows, RMA Manager, Web Servie, RCC).
Post Reply
bobay
Posts: 2
Joined: Mon Apr 07, 2003 6:00 pm
Location: Netherlands

Variable length and types

Post by bobay »

Hi,

i'm in the process of setting up ODBC logging into an SQL database. I was wondering if you could give me an overview (if possible) of the length and types (char, numerical, date) of the various fields that are used in test and replies.
I'm trying to avoid "surprises" when writing to the database.

Thanks

Bob
KS-Soft
Posts: 12821
Joined: Wed Apr 03, 2002 6:00 pm
Location: USA
Contact:

Post by KS-Soft »

We already have similar topics, e.g.
http://www.ks-soft.net/cgi-bin/phpBB/vi ... php?t=3601

Well, it depends on your settings (e.g. length of test names) and what exactly variables do you plan to use in the query.
E.g do you plan to use %Status% variable or %SimpleStatus%? or may be %StatusID%?
There are a lot of variables and usually you can determine type and size of the field by checking description of the variable
http://www.ks-soft.net/hostmon.eng/mfra ... .htm#macro

E.g. %TestName%, %TestedObjectInfo%, %Reply%, %LastReply% and other "not fixed" variables may return string up to 4090 characters long. Do you need to reserve so much space for test name? Probably not. If you are using short name, reserve 40 chars, if you are using long names, reserve 100 chars or use varchar data type...

Regards
Alex
bobay
Posts: 2
Joined: Mon Apr 07, 2003 6:00 pm
Location: Netherlands

Post by bobay »

Thanks for the info Alex, missed the thread.
Post Reply