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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Table Memo (*.fpt) file size accumulate when using General Field 1

Status
Not open for further replies.

GNMN

Programmer
Oct 14, 2003
20
AP
I am developing student’s profile (VFP7) and using General Field to store ID picture using this command {APPEND GENERAL stud.pix FROM id001.jpg LINK}.

The problems are:
1.The size of the Table Memo (.FPT) is quite large compared to the actual file size of the inserted ID picture (id001.jpg). How can I make the Table Memo file size is equal or even smaller to the file size of the actual ID picture?

2.The file size of Table Memo (.FPT) has not reduced to its original size when the picture from database was removed using {APPEND GENERAL stud.pix} command. Is there any trick to remove picture(s) from General Field?

Please help.

Thanks!


Gene
 
Is there any trick to remove picture(s) from General Field?
i use BLANK FIELD <GenFieldName>

hope this help. peace! [peace]

kilroy [trooper]
philippines

"Illegitimis non carborundum!"
 
Try 'PACK'ing the table, which should clean up deleted record data in the fpt.

That said, most will recommend you store the binaray of the jpg in a memo field and not a general field. Use strtofile() and filetostr(). Files ARE NOT easily recovered from a ggeneral field.

Brian
 
Brian & kilroy,

Thanks for the Tips.

Surprisingly, PACKing the table reduces the size of .FPT eventhough there were no deleted records in the table, in fact it is just replacing a blank data (as kilroy suggested) in General Field. Problem #2 was solved.

I am still having a big problem in problem #1. I tried to insert a picture with 27KB in .FPT but unfortunately after saving the database it was 694KB. Please help.

Tnx.


Gene
 
GNMN

If you do a search here on Tek-Tips or any other VFP site, you will find that it is NOT recommended to store picture files into memo fields (Unless it is a single pictures like a company logo). The problem is the bloating of the memo field. It is always been a problem and there isn't any solution. The recommendation is to use textfields and store the path of where you picture file is on your hard drive.

Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top