 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
JS Guest
|
Posted: Wed Jun 25, 2003 7:23 pm Post subject: newbie - making join queries writable |
|
|
As I understand it, not all sql queries can be made writable. If I
have a TDBGrid that displays the results of this query:
select table1.field1, table2.field2 from table1, table2, where
table1.field3=table2.field3
Then the user cannot make changes to the values in those fields.
Am I understanding that correctly? If so, is there an accepted
workaround? All I could think of was to have multiple TQuery objects
on the form with multiple DBEdit fields and keep changing the sql
statements to duplicate a join statement.
Any better ways?
This is with Delphi 5 and odbc access to a mysql database server.
Thanks,
|
|
| Back to top |
|
 |
Sundial Services Guest
|
Posted: Wed Jun 25, 2003 8:59 pm Post subject: Re: newbie - making join queries writable |
|
|
JS wrote:
| Quote: | As I understand it, not all sql queries can be made writable. If I
have a TDBGrid that displays the results of this query:
select table1.field1, table2.field2 from table1, table2, where
table1.field3=table2.field3
Then the user cannot make changes to the values in those fields.
Am I understanding that correctly? If so, is there an accepted
workaround? All I could think of was to have multiple TQuery objects
on the form with multiple DBEdit fields and keep changing the sql
statements to duplicate a join statement.
|
This type of query is not updatable. You can't open a "live query view" on
it.
What you can do, however, and what I'd recommend anyway that you do, is to
run the query, put the results into a local table of some kind {or just
store 'em in memory}, update them there, and then .. if the user presses
"OK" .. execute separate queries to update the actual data.
----------------------------------
Fast automatic table repair at a click of a mouse!
http://www.sundialservices.com/products/chimneysweep
|
|
| Back to top |
|
 |
Greg Gailer Guest
|
Posted: Sun Oct 29, 2006 9:01 am Post subject: Re: Rave Reports |
|
|
Jean Botes wrote:
| Quote: | Hi
What is the most effective way to send data to a report and print it?
I print barcodes but the text is cut of, although it is complete in the
database.
Prints: 'ebenha'
In database reads: 'ebenhaezer vneck'
Any help will be apreciated, thanks
Jean
Hi Jean, |
I have set up parameters in my Rave reports (the help file tells you
how) and then pass the values from the delphi program using the:
SetParam('Parameter',String);
function. The parameters are passed as string so you have to convert
them first if they are anything other than that.
I don't know if this is the most effective way but it was simple for me
to use.
Greg |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|