Sponsored Content
Full Discussion: Integer to String
Top Forums Programming Integer to String Post 5599 by psilva on Friday 17th of August 2001 12:14:56 PM
Old 08-17-2001
Computer

Tank you very much...it worked just fine!!!!

Thanx
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

convert from an integer to a string

i want to convert from an integer to a string..in unix...i am writing a C program with embedded SQL... I remeber using itoa...but for some reason it doesnt work......i cant find it in the manual..... Maybe that is the wrong command..... but i have checked Dev Studio.....and it doest exist in the... (6 Replies)
Discussion started by: mojomonkeyhelper
6 Replies

2. UNIX for Dummies Questions & Answers

conersting string to integer

Hi i am writing a shell script; I need to convert a string to integer so that i can use it in the 'awk' command to choose a field. can you please help me. thank you. (2 Replies)
Discussion started by: abb058
2 Replies

3. Shell Programming and Scripting

Checking if string contains integer

G'day guys, first post so be gentle. I need help with some code to work out if a variable (string) contains any integers. The valid variable (string) must contain only letters. Also need to be able to work out if a variable contains only integers. Any help greatly appreciated. (7 Replies)
Discussion started by: haz
7 Replies

4. Shell Programming and Scripting

Converting integer to String

Hi everyone, I would like to know how to convert an integer to a string. for instance if i=1 i would like to creat a variable called constant1. i want to do this in a for loop so for each value of i, i create a new variable such as constant2, constant3,... and so on. for i in 1 2 3 do ... (1 Reply)
Discussion started by: ROOZ
1 Replies

5. Shell Programming and Scripting

Comparing string and integer in IF

hi, I need to create an IF condition. I read a line from a file and get the 5 word using space as a delimited. This word can have only two values either '*' or '1-5' I need to write an IF condition for two cases. I can either compare it to * or 1-5(or even 1 by cutting and getting only the... (3 Replies)
Discussion started by: kaushys
3 Replies

6. UNIX for Dummies Questions & Answers

integer to string

Hi all, is there an easy way to convert integer to string in bash? I have numbers like 1, 2, ..., 112, ... and I would like to get 001 002 003 004 ... Thank you, Sarah (4 Replies)
Discussion started by: f_o_555
4 Replies

7. Shell Programming and Scripting

how to compare string integer with an integer?

hi, how to I do this? i="4.000" if ; then echo "smaller" fi how do I convert the "4.000" to 4? Thanks! (4 Replies)
Discussion started by: h0ujun
4 Replies

8. UNIX for Dummies Questions & Answers

[Solved] How to extract integer out of a string?

Input: XXX:1,XXX:3,XXX:3 Output: A=1 B=3 C=3 Below code is what i do currently. However it doesn't work out for all cases. As some times the last digit extracted is giving me error. It cant be used for arithmetic computation. Any better methods out there? If possible, can you... (9 Replies)
Discussion started by: bananamen
9 Replies

9. Shell Programming and Scripting

String to integer

I am on HP-UX using ksh in the script. MaxSal=`sqlplus -silent /nolog <<EOF connect / as sysdba whenever sqlerror exit sql.sqlcode set pagesize 0 feedback off verify off heading off echo off select max(sal) from emp1; select max(sal) from emp2; select max(sal) from emp3; exit; EOF`... (3 Replies)
Discussion started by: bang_dba
3 Replies

10. Shell Programming and Scripting

Converting string to integer

I have a function that is supposed to check for user processes and wait for 0 count before exiting the function. I am sure I have more than one issue in my code, but the stumbling block right now is that I am trying to convert the value of my variable from a string to integer. process_count... (10 Replies)
Discussion started by: MIA651
10 Replies
Mail::SpamAssassin::BayesStore(3pm)			User Contributed Perl Documentation		       Mail::SpamAssassin::BayesStore(3pm)

NAME
Mail::SpamAssassin::BayesStore - Storage Module for default Bayes classifier DESCRIPTION
This is the public API for the Bayesian store methods. Any implementation of the storage module for the default Bayes classifier must implement these methods. METHODS
new public class (Mail::SpamAssassin::BayesStore) new (Mail::SpamAssassin::Plugin::Bayes $bayes) Description: This method creates a new instance of the Mail::SpamAssassin::BayesStore object. You must pass in an instance of the Mail::SpamAssassin::Plugin::Bayes object, which is stashed for use throughout the module. DB_VERSION public instance (Integer) DB_VERSION () Description: This method returns the currently supported database version for the implementation. read_db_configs public instance () read_db_configs () Description: This method reads any needed config variables from the configuration object and then calls the Mail::SpamAssassin::Plugin::Plugin::Bayes read_db_configs method. tie_db_readonly public instance (Boolean) tie_db_readonly () Description: This method opens up the database in readonly mode. tie_db_writable public instance (Boolean) tie_db_writable () Description: This method opens up the database in writable mode. Any callers of this methods should ensure that they call untie_db() afterwards. untie_db public instance () untie_db () Description: This method unties the database. calculate_expire_delta public instance (%) calculate_expire_delta (Integer $newest_atime, Integer $start, Integer $max_expire_mult) Description: This method performs a calculation on the data to determine the optimum atime for token expiration. token_expiration public instance (Integer, Integer, Integer, Integer) token_expiration(\% $opts, Integer $newest_atime, Integer $newdelta) Description: This method performs the database specific expiration of tokens based on the passed in $newest_atime and $newdelta. expire_old_tokens public instance (Boolean) expire_old_tokens (\% hashref) Description: This method expires old tokens from the database. expire_old_tokens_trapped public instance (Boolean) expire_old_tokens_trapped (\% $opts) Description: This methods does the actual token expiration. XXX More docs here about the methodology and what not sync_due public instance (Boolean) sync_due () Description: This methods determines if a sync is due. expiry_due public instance (Boolean) expiry_due () Description: This methods determines if an expire is due. seen_get public instance (Char) seen_get (String $msgid) Description: This method retrieves the stored value, if any, for $msgid. The return value is the stored string ('s' for spam and 'h' for ham) or undef if $msgid is not found. seen_put public instance (Boolean) seen_put (String $msgid, Char $flag) Description: This method records $msgid as the type given by $flag. $flag is one of two values 's' for spam and 'h' for ham. seen_delete public instance (Boolean) seen_delete (String $msgid) Description: This method removes $msgid from storage. get_storage_variables public instance (@) get_storage_variables () Description: This method retrieves the various administrative variables used by the Bayes storage implementation. The values returned in the array are in the following order: 0: scan count base 1: number of spam 2: number of ham 3: number of tokens in db 4: last expire atime 5: oldest token in db atime 6: db version value 7: last journal sync 8: last atime delta 9: last expire reduction count 10: newest token in db atime dump_db_toks public instance () dump_db_toks (String $template, String $regex, @ @vars) Description: This method loops over all tokens, computing the probability for the token and then printing it out according to the passed in template. set_last_expire public instance (Boolean) _set_last_expire (Integer $time) Description: This method sets the last expire time. get_running_expire_tok public instance (Time) get_running_expire_tok () Description: This method determines if an expire is currently running and returns the time the expire started. set_running_expire_tok public instance (Time) set_running_expire_tok () Description: This method sets the running expire time to the current time. remove_running_expire_tok public instance (Boolean) remove_running_expire_tok () Description: This method removes a currently set running expire time. tok_get public instance (Integer, Integer, Time) tok_get (String $token) Description: This method retrieves the specified token ($token) from storage and returns it's spam count, ham acount and last access time. tok_get_all public instance (@) tok_get_all (@ @tokens) Description: This method retrieves the specified tokens (@tokens) from storage and returns an array ref of arrays spam count, ham count and last access time. tok_count_change public instance (Boolean) tok_count_change (Integer $spam_count, Integer $ham_count, String $token, Time $atime) Description: This method takes a $spam_count and $ham_count and adds it to $token along with updating $tokens atime with $atime. multi_tok_count_change public instance (Boolean) multi_tok_count_change (Integer $spam_count, Integer $ham_count, \% $tokens, String $atime) Description: This method takes a $spam_count and $ham_count and adds it to all of the tokens in the $tokens hash ref along with updating each tokens atime with $atime. nspam_nham_get public instance (Integer, Integer) nspam_nham_get () Description: This method retrieves the total number of spam and the total number of ham currently under storage. nspam_nham_change public instance (Boolean) nspam_nham_change (Integer $num_spam, Integer $num_ham) Description: This method updates the number of spam and the number of ham in the database. tok_touch public instance (Boolean) tok_touch (String $token, Time $atime) Description: This method updates the given tokens ($token) access time. tok_touch_all public instance (Boolean) tok_touch_all (@ $tokens, Time $atime) Description: This method does a mass update of the given list of tokens $tokens, if the existing token atime is < $atime. cleanup public instance (Boolean) cleanup () Description: This method performs any cleanup necessary before moving onto the next operation. get_magic_re public instance get_magic_re (String) Description: This method returns a regexp which indicates a magic token. sync public instance (Boolean) sync (\% $opts) Description: This method performs a sync of the database. perform_upgrade public instance (Boolean) perform_upgrade (\% $opts) Description: This method is a utility method that performs any necessary upgrades between versions. It should know how to handle previous versions and what needs to happen to upgrade them. A true return value indicates success. clear_database public instance (Boolean) clear_database () Description: This method deletes all records for a particular user. Callers should be aware that any errors returned by this method could causes the database to be inconsistent for the given user. backup_database public instance (Boolean) backup_database () Description: This method will dump the users database in a machine readable format. restore_database public instance (Boolean) restore_database (String $filename, Boolean $showdots) Description: This method restores a database from the given filename, $filename. Callers should be aware that any errors returned by this method could causes the database to be inconsistent for the given user. db_readable public instance (Boolean) db_readable () Description: This method returns whether or not the Bayes DB is available in a readable state. db_writable public instance (Boolean) db_writable () Description: This method returns whether or not the Bayes DB is available in a writable state. perl v5.14.2 2011-06-06 Mail::SpamAssassin::BayesStore(3pm)
All times are GMT -4. The time now is 01:16 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy