Solved

Query result

Posted on 1998-11-21
2
151 Views
Last Modified: 2010-04-04
OK, I've used sql to get the sum of a table field, but what code do i need to show this result in a DBText field. Thanx.
0
Comment
Question by:cavalry
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 8

Accepted Solution

by:
ZifNab earned 10 total points
ID: 1347509
cavalry,

 use select Sum(..) as sumofvalue from ...

Then go to the fieldeditor. Read in fields, there you'll find sumofvalue. Then go to dbtext. Select correct database, select sumofvalue as field.

Regards, Zif.
0
 
LVL 27

Expert Comment

by:kretzschmar
ID: 1347510
hi cavalry,

a other method to show static values
if the sum the only field in your query you can use Fields[0]

  query1.open;
  label1.Caption := floattostr(query1.Fields[0].AsFloat);
  query1.Close;

thats recommends no use of dbtextfield.

if you will use dbtextfield, then use zifs answer

meikl

meikl
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…

695 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question