Página 1 de 1

Comments on topic "How to SCAN substrings in a dbf - Summer"

Enviado: 30 Jan 2013 20:35
por alxsts
This topic comes to explain code details on topic How to SCAN substrings in a dbf - Summer 87
marge0512 escreveu: APPEND Blank
REPLACE Field_Name with "COMPNY_NAM"
REPLACE Field_Type with "C" <------------Why value "C"? What does that mean.
REPLACE Field_Len with 25
REPLACE Field_Dec with 0 <------------Also, the same for this value.
In xBase tables, data is stored in the form of rows. These rows are made up of columns. Each column has a particular set of characteristics, as you can see in the above code:
- Field name, up to ten chars is the name of the field
- Field type: "C"haracter, "N"umeric, "D"ate, "L"ogical and "M"emo is the data type
- Field Length: numeric value indicating field length in bytes (10 when Field type is Memo) is the field length
- Field Decimal is the decimal places quantity when Field type is Numeric
marge0512 escreveu:Also, with *Close struct table
*--------------------
USE <-----------Do I need to be concerned with EXCLUSIVE or SHARED?
When you emit a USE command without any argument Clipper closes the table open in the currently selected work area. Since it's closing, no worries about shared or exclusive...
marge0512 escreveu: DBEDIT(6, 19, 19, 60, {"tmpTable->CASE_LNAME"},"_REC_FND_", NIL, {"Select a name "}) <---------Why does DBEDIT use
{"tmpTable->CASE_LNAME"} and not
{"tmpTable->COMPNY_NAM"} at all?
Sorry, this confusion in your mind is my fault. Actually, the contents of that field is the search result we found using the dollar operator either in CASE_LNAME or COMPNY_NAM fields. I kept the same column name but I could give it another name (e.g. SrchResult) to keep things clear

You'll find further details seeing specific commands or functions in the manual.

Any other doubt? Post again.

Comments on topic "How to SCAN substrings in a dbf - Summer"

Enviado: 31 Jan 2013 12:06
por marge0512
Thanks! That clears everything up. Would you still need REPLACE Field_Dec with 0 since the field type is a character? Just curious.

Thanks again!!

Comments on topic "How to SCAN substrings in a dbf - Summer"

Enviado: 31 Jan 2013 12:18
por Pablo César
Hi Marge !

There is not decimals replacing when field is character type. For declaration/creates dbf this is ignored.

Comments on topic "How to SCAN substrings in a dbf - Summer"

Enviado: 04 Fev 2013 12:08
por marge0512
Ok, thank you!