|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
Getting the output of a SQL query into a text control
Hello all.
I have an Access 2002 database that I am trying to develop for my school's library. The pertinent tables and fields that I am having trouble with are: Table: Accession Number Designator (a three char string) Date Entered Daily Counter (int) Table: Work AccessNum (a string concatenated from Designator, Date Entered, and Daily Counter) Form: Entry Designator (combo box) Date Entered (uses Date()) Daily Counter (here's where the trouble starts) Accession Number (a display of the concatenation via VB of the three fields above) I have a SQL query that works when run by itself: SELECT Max([Accession Number].[Daily Counter])+1 AS Expr1 FROM [Accession Number] WHERE ((([Accession Number].[Date Entered])=[Forms]![Entry].[Date Entered]) AND (([Accession Number].Designator)=[Forms]![Entry].[Designator] How do I get the value returned from this SQL Query into a text box on my form, namely the Daily Counter text box? This seems (at least to me) like it should be a simple matter of using the expression builder, but I have been banging my head on this for weeks now. I appreciate any information anyone can provide. Thank you. Last edited by slide23 : May 19th, 2004 at 06:36 PM. |
![]() |
| Viewing: Dev Shed Forums > Databases > MS SQL Development > Getting the output of a SQL query into a text control |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|