Re: Database field in control

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Looks like I got it solved, just created a alias table field in the database and referenced it from the control

Select .....[RUN_OUT].[R_ID] as RunIN From .....

ComboRunIn.BoundText = rst!RunIN

adds a bit to the query but does the trick.


Bryan wrote:
All:

Would appreciate some help in filling a textbox with a field from an access database query where the field is part of a table alias. there is two identical tables in the query, but they are distinct from each other by their table alias name

The following variations do not work, no problem doing this in Access using the double square brackets but not in VB.


ComboRunIn.BoundText = rst![RUN_OUT].[R_ID]
ComboRunIn.BoundText = rst![RUN_OUT.R_ID]
ComboRunIn.BoundText = rst!RUN_OUT.R_ID

Thanks in advance
.



Relevant Pages

  • Re: The specified Field Could refer to more than one table... Access 2
    ... Then compact the database. ... Right-click the table in the upper pane of query design, ... Set the Alias property to some other unused name, e.g. atDispositionRecords Access will change its name, and the instances in the SQL statement that use this name. ... I have a report that works perfectly in 2003 however when I ...
    (microsoft.public.access.reports)
  • Re: The specified Field Could refer to more than one table... Acce
    ... Then compact the database. ... Next, alias the table. ... Right-click the table in the upper pane of query ... The report is built from a query which has a joint relationship between a ...
    (microsoft.public.access.reports)
  • Re: alias/source properties in QUERY
    ... Nick 'The database Guy' wrote: ... I just use a table alias to shorten the text of my queries. ... the sub query, specificially in the WHERE clause on customer_id and id_field. ...
    (microsoft.public.access.queries)
  • Re: The specified Field Could refer to more than one table... Acce
    ... Then in the upper query (the one that uses that one, ... I've unchecked the boxes for AutoCorrect and compacted the database, ... Next, alias the table. ... I have a report that works perfectly in 2003 however> when ...
    (microsoft.public.access.reports)
  • RE: Field aliases not being returned properly in A2007
    ... I was wondering if you found a fix for the alias ... Sharepoint Lists as my data repository for about 3 months now. ... This has totally delayed the project I'm working on, I need this query to ...
    (microsoft.public.access.queries)