UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Fields Not Showing Up In The Dynaset, Access 2013    
 
   
mmadani
post Jan 10 2018, 06:37 PM
Post#1



Posts: 342
Joined: 27-June 08



SELECT SPR_Log.id, SPR_Log.name, SPR_Log.StationID, SPR_Log.State, SPR_Log.substate, SPR_Log.CR_reference, SPR_Log.sub_system, SPR_Log.CR_category, SPR_Log.CR_type, SPR_Log.headline, SPR_Log.severity, SPR_Log.submitter, SPR_Log.description, SPR_Log.ID1, SPR_Log.implementer, SPR_Log.implementation, SPR_Log.validation_description, SPR_Log.impacted_items, SPR_Log.proposed_change, SPR_Log.product, SPR_Log.submitter_date, SPR_Log.Closure_date, SPR_Log.record_date, IIf([record_date]="",Null,DateDiff("d",CDate(Left([record_date],InStr([record_date],"GMT")-1)),Date())) AS Age, IIf([Age] Between 0 And 29," Less than 30 days",IIf([Age] Between 30 And 60,"30 - 60 days",IIf([Age] Between 60 And 90,"60-90 days",IIf(IsNull([Age]),"No Age",IIf([Age]>90,"Over 90 days"))))) AS bucket, SPR_Log.Primary_Block, SPR_Log.Secondary_Block, SPR_Log.submitter_CR_reference, SPR_Log.Comments
FROM SPR_Log
ORDER BY SPR_Log.id;


SPR_Log.State this field [State] which is a text field does not show up as a column in the resultant set of records. I can remove the date aging , it has nothing to do with this I don't believe.

What am I doing wrong?

Thanks
Mike pullhair.gif
Go to the top of the page
 
RJD
post Jan 10 2018, 07:10 PM
Post#2


UtterAccess VIP
Posts: 8,809
Joined: 25-October 10
From: Gulf South USA


Hi Mike: Hard to know without seeing more, but you might try this ... Run the query, then Sweep over the fieldname headers just before and after the State field, then right-click on the headers, then select Unhide Fields, then see if State is unchecked. If so, check it and close. Does it show now?

I am assuming you are not getting a prompt for the field when you run the query and that the field might just be hidden right now.

And if this does not work, look closely and see if the field width is just really, really narrow.

Failing that, perhaps you could post a cut-down db for us to look at.

HTH
Joe
Go to the top of the page
 
mmadani
post Jan 10 2018, 07:21 PM
Post#3



Posts: 342
Joined: 27-June 08



Thanks Joe. The filed in checked to show, I will do what you suggested and let you know.

Thanks
Mike
Go to the top of the page
 
RJD
post Jan 10 2018, 07:27 PM
Post#4


UtterAccess VIP
Posts: 8,809
Joined: 25-October 10
From: Gulf South USA


Oh, and you might look all across the query result, field by field. A field can be dragged to another position in the result view, although it shows in the same position in the SQL. Just another thought.

Again, if you can't find the issue, if you could post a cut down db, someone could look at it - and this usually results in a quick resolution ...

HTH
Joe
Go to the top of the page
 
mmadani
post Jan 11 2018, 07:44 PM
Post#5



Posts: 342
Joined: 27-June 08



Hello Joe;

I checked every thing and I even enabled the output all fields, still unable to show field named "State"

I am attaching a stripped down version

Thanks for your time

Mike


Attached File(s)
Attached File  UtterDB.zip ( 153.98K )Number of downloads: 3
 
Go to the top of the page
 
RJD
post Jan 11 2018, 08:01 PM
Post#6


UtterAccess VIP
Posts: 8,809
Joined: 25-October 10
From: Gulf South USA


Hi Mike: State is there, but hidden. Although you put State in the first position in the SQL, it is between Headline and StationID for display and hidden. I simply right-clicked on any header in datasheet view and chose Unhide Fields and checked the unchecked State field. Then it displayed as you designed it between Headline and Station.

Other things are displayed in a different order than the SQL as well, and some still hidden.

HTH
Joe
Attached File(s)
Attached File  UtterDB_Rev1.zip ( 152.74K )Number of downloads: 5
 
Go to the top of the page
 
moke123
post Jan 11 2018, 08:46 PM
Post#7



Posts: 1,318
Joined: 26-December 12
From: Western Ma.,L.I.,N.Y.,Jupiter,Fl.



pmfji, I had an issue a long time ago with an address table where I used state as a field in the table. I dont even remember what it was but as State is a reserved word in SQL I changed it to txtState and my issue went away.
Just a thought.
Go to the top of the page
 
mmadani
post Jan 11 2018, 09:06 PM
Post#8



Posts: 342
Joined: 27-June 08



Thank you. That's one thing I forgot to do

I will sleep better tonight

Thanks
Mike notworthy.gif
Go to the top of the page
 
mmadani
post Jan 11 2018, 09:16 PM
Post#9



Posts: 342
Joined: 27-June 08



Moke123
Thanks for your input. state here is like a Status description. I did not know that state is a reserved word. I will look into it

Regards

Mike thumbup.gif
Go to the top of the page
 
RJD
post Jan 11 2018, 09:21 PM
Post#10


UtterAccess VIP
Posts: 8,809
Joined: 25-October 10
From: Gulf South USA


Hi Moke:

QUOTE
...but as State is a reserved word in SQL...

I can't find State in any reserved word list for Access. I use it all the time as a field name. In any case, Mike is using State in a sense other than in an address (not that it makes any difference in the discussion). Once I unhid the field in the query (in datasheet view), State displayed just fine.

Mike:

I assume you were responding to my last post and revision to your db. If so, you are very welcome. And glad you will sleep better tonight! thumbup.gif

Regards,
Joe
Go to the top of the page
 
moke123
post Jan 12 2018, 08:47 AM
Post#11



Posts: 1,318
Joined: 26-December 12
From: Western Ma.,L.I.,N.Y.,Jupiter,Fl.



I dont remember the problem I had but recalled seeing "State" as a reserved word and as such I have since then always added a prefix to State such as txtState.
Its listed in allen Browns list as a future SQL reserved word.

And its listed here ...SQL reserved words

Go to the top of the page
 
RJD
post Jan 12 2018, 11:04 AM
Post#12


UtterAccess VIP
Posts: 8,809
Joined: 25-October 10
From: Gulf South USA


Hi Moke: Thanks. Curious. I do see STATE on the reserved word list you cited - but do not find it on any Access list. I have used State as a field name in Access for 25 years or so without difficulty. And, as I said, the problem in this thread was that the field was hidden in the query result display. Once that was unhidden, State showed without issue.

But I will store this in ready memory in case I ever run into a problem with this.

Thanks for jumping in.

Regards,
Joe
Go to the top of the page
 


Custom Search
RSSSearch   Top   Lo-Fi    26th September 2018 - 03:46 AM