What is the advantage of using a database verses managing the tables directly? [sig]<p> Pete<br><a href=mailto:blindpete@mail.com>blindpete@mail.com</a><br><a href= > </a><br>What your mother told you is true! You will go blind! (from moonshine anyway)[/sig]
Long table names
Comments for each field, table and database
Long field names
Captions for fields that display in Browse windows and Grid Column headers
Default values on fields
Primary and candidadte fields
Field-level rules and record-level rules
Triggers
Persistent relationships between database tables
Stored procedures
Connections to remote data sources
Local and remote views
IMHO, it's a lot simpler using free tables unless you really need those features.
To add to Chris' last comment: its one more thing to go wrong.
Long field names are nice, and may itself be reason enough. The VFP RI builder has a reputation for having glitches and not the best performer in the world.
If you really need robust engine-level referential integrity enforcement and constraints, AND you have the flexibility, you might be better served by using MSDE or SQL Server. [sig]<p>Robert Bradley<br><a href=mailto: > </a><br><a href=
I would strongly argue against using databases unless you have some definite need for a particular feature. Databases get "nasty" about a few things that were formerly simple. I can't remember precisely what they were now because I have stopped using them. But I remember having lots of frustration with things that were just a normal part of my programming in the past.
They (databases) have some nice concepts ... granted ... but the frustration outweighed the gains in my book. AND .. I really have no particular use for the features they provide.
Thanks all!
I toyed with them one day a few years ago. I didn't see much advantage to them then (made my desktop lock several times too). I see little has changed.
Are DBC's required for ODBC with another datbase format like Access? All the documentation examples I have seen use DBC. I'd rather not if I don't have to. [sig]<p> Pete<br><a href=mailto:blindpete@mail.com>blindpete@mail.com</a><br><a href= > </a><br>What your mother told you is true! You will go blind! (from moonshine anyway)[/sig]
If you want to use persistent remote views, which require
A) a storage place (the DBC); and
B) a named connection (which is typically also stored in the DBC)
then you'll need one.
I'm writing an app where, due to security reasons, I don't want a persistent named connection, so I am using SQLSTRINGCONNECT() along with non-updatable remote views; I won't need a DBC. [sig]<p>Robert Bradley<br><a href=mailto: > </a><br><a href=
Robert, you still using non-updatable remote views? what about my answer on this problem? I found a solution... [sig]<p>Vlad Grynchyshyn<br><a href=mailto:vgryn@softserve.lviv.ua>vgryn@softserve.lviv.ua</a><br>[/sig]
I'll send you my attempt via e-mail and if you can see where I went wrong, or where your approach and my approach differ, I'll make a FAQ of it and give you all the credit!
What I'm doing now, and what works, is I make a local cursor from the primary SQLS table using SQLEXEC(). I then bind my controls' ControlSource to the appropriate columns. Upon pushing cmdSave, I roll through the cursor and build an INSERT or UPDATE statement, and SQLEXEC() it. Works fine, but I feel uneasy about the handling of UPDATE - because I'm not really checking to see what's changed. This is the one area where an updatable remote view does a whole lot of the grunt work for you, and does it much faster than we can do it in Fox code.
To explain why I'm going through all this: persistent remote views require storage in a DBC, and (more importantly) require a persistent named connection stored in the DBC. This named connection must either contain the username/password, or must point to a Windows DSN that contains the username/password.
Since DBCs are normally shared, and decent database security forbids sharing of usernames, and storing username/passwords anywhere is not a good idea anyway, named connections are out - and, therefore, so are persistent (stored) updatable remote views.
The neat trick would be to create a local view/cursor via SQLEXEC(), then force it to be updatable - and this is what Vlad thinks he has found the secret ingredient for. [sig]<p>Robert Bradley<br><a href=mailto: > </a><br><a href=
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.