Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Index Names
Message
From
17/05/2006 22:00:10
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
17/05/2006 21:55:53
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01122960
Message ID:
01123079
Views:
22
>It's an idea worth some time. I don't think anything is going to make this a less onerous task though. I have to manually create all the indices, and the way they've set it up, in far too many cases, the tags themselves are going to look like Str(IntegerField1) + Str(IntegerField2) because uniqueness depends on more than one integer field - that is, unless you know an easier way of compounding integer fields into an index tag.

Not easier, but more efficient:

Instead of
str(IntField1) + str(IntField2) && 20 bytes
use:
bintoc(IntField1) + bintoc(IntField2) && 8 bytes
> And then the foreign key indices will have to follow the same pattern. I'd like to get my hands on the person who came up with the SQL database design.

Yeah, it looks like a real pain in the acronym. But - can't you add an integer key yourself? For the foreign keys, you will have to do a lookup in the table that contains the primary keys, but it may save you trouble in the long run.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform