VFP has only 5 constant types: , numerical constant: numerical type constant can be an integer or real number, for example: 56, 69.8, etc. are numerical constants; , character type constant: character type: character type The constant is a string composed of characters, spaces, and numbers included in the boundary symbol; the fixed boundary can be a single quotation number, dual quotation, and square bracket. When a certain boundary character itself is an component of character constant, another type of fixed character should be selected. For example: "ABCD", Professor „, [Wang Ming] is the character type constant of the correct writing method; . Logical constant: logic constant only 2 values:" true "and" fake ". .,. T.,. Y.,. Y., Indicated "True", using .f.,. F.,. N., Indicated "fake". Note: The points on both sides should not be removed However, the use of spaces can be replaced; 4. Date type constant: Date -type constant must be included in parentheses, for example: {^95.01.12}, {^01/12/95} are the correct writing methods of date constant . The "^" keyboard in the bracket is added to solve the "Millennium Worm" problem; 5. Date time type constant: Date time type constant must also be included in brackets, for example: {^^^^^ 2005/12/06 11: 12: 32pm}, {2005.12.06 11: 12: 32pm}, {^2005-12-06 11: 12: 32pm} All are the correct date Writing of time -type constant. Note: There must be space between date and time data.
6 constant data types of VFP: character type, numerical type, currency type, date type, date time and logic type
VFP has only 5 constant types:
, numerical constant: numerical type constant can be an integer or real number, for example: 56, 69.8, etc. are numerical constants;
, character type constant: character type: character type The constant is a string composed of characters, spaces, and numbers included in the boundary symbol; the fixed boundary can be a single quotation number, dual quotation, and square bracket. When a certain boundary character itself is an component of character constant, another type of fixed character should be selected. For example: "ABCD", Professor „, [Wang Ming] is the character type constant of the correct writing method;
. Logical constant: logic constant only 2 values:" true "and" fake ". .,. T.,. Y.,. Y., Indicated "True", using .f.,. F.,. N., Indicated "fake". Note: The points on both sides should not be removed However, the use of spaces can be replaced;
4. Date type constant: Date -type constant must be included in parentheses, for example: {^95.01.12}, {^01/12/95} are the correct writing methods of date constant . The "^" keyboard in the bracket is added to solve the "Millennium Worm" problem;
5. Date time type constant: Date time type constant must also be included in brackets, for example: {^^^^^ 2005/12/06
11: 12: 32pm}, {2005.12.06
11: 12: 32pm}, {^2005-12-06
11: 12: 32pm} All are the correct date Writing of time -type constant. Note: There must be space between date and time data.