Query Help-1st Time Post

Jun 5, 2007

hi this is my first post. This is probably so basic you will think i am stupid but your help would be appritiated.
I have a very simple database which displays the questions stored in a table in a form . The recipent answers the questions generaly yes or No. On answering yes or no i wish to attach values (hidden) to thier answers and then based on the answers produce a simple set of bar charts. I have tried but do not know how to assign the values to the questions . i would then like to produce 5 bar charts 1 for each of the catogories and one as a total (as an overall and also in sub groups of which there are 4 each of which has a field with a specific prefix either b,c,r,s dependant on the type of question. )

hope someone can help


Page Jump

View Replies


ADVERTISEMENT

Cannot Load Post From A Specific Date And Time.

Dec 11, 2005

Hi, i cannot load posts from a specified date and time



PostDate = now()

'AID = accountID of the poster

'read post after added into DB
Set rsForum = Server.CreateObject("ADODB.Recordset")
strForumSQL = "Select * From tblPost where tblPost.PostDate = '"&PostDate&"' and tblPost.PostBy = "&AID&""
rsForum.Open strForumSQL, strForumCon,3,3
PostID = rsForum("PostID")


I gets an error when posting messages, i think is because: tblPost.PostDate = '"&PostDate&"'

PostDate is no text field, its a Date field and i tried to use this symbol: ' around postdate, i also tried to not use it, but then i gets another error:

[Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'tblPost.PostDate = 12/11/2005 10:32:50 AM and tblPost.PostBy = 6'.

but that is because the date/time format uses spaces.
How can i fix this?

Thanks in advance

View 4 Replies View Related

Newbie Post - Query Question

Mar 14, 2006

Hi, i'm a newbie so please be gentle :)

ok, i have 2 tables, one is for part number and product ID and the other has product ID and Vehicle details.

i know how to set up a parameter query but just can't quite get the result i want, which is to set up a query based on the result of the first query.

in short i want to enter a part number and it comes up with the vehicle details.

Many thanks in advance

Ty

View 5 Replies View Related

Queries :: Post To Query From Form

Aug 31, 2013

I have a from where users select from one of four Options. The Print putton on the form enters text into an unbound textbox based on the selection. Here is the code:

If Me.optWhichList = 1 Then
Me.txtWhichList = WHAT TO PUT HERE
ElseIf Me.optWhichList = 2 Then
Me.txtWhichList = "LS"
ElseIf Me.optWhichList = 3 Then
Me.txtWhichList = "AS"
Else: Me.txtWhichList = "SM"

In the Query I have teh Criteria as
[Forms]![popfrmChooseMailingLabels]![txtWhichList]

Works fine for options 2, 3 and 4 which choose the relevant criteria in the corresponding Query, but I want Option 1 to select all records. What do I put there so that all records are selected (i.e., no criteria)

View 8 Replies View Related

Combo Box Query To Post Result To A Seperate Query

Sep 27, 2006

Hello, I have a combo box on a form which lists some names generated from a table.

I would like the selected name to be inputted into the 'critera' of another query called 'qryPBCustLevel' and for that query to be run.

I have tried to code this, but it is crashing at the point it trys to add the name into the query.

Can anyone help? Code listed below.

Sub cmbPB_AfterUpdate()

'Set the Dimensions of the Module
Dim strSQL As String, strOrder As String
Dim dbNm As Database
Dim qryDef As QueryDef
Set dbNm = CurrentDb()

'Constant Select statement for the Query definition

strSQL = "SELECT DISTINCT tblTempPB.PB_NAME" & _
"FROM tblTempPB"

strOrder = "tblTempPB.PB_NAME;"

' Find the record that matches the control.
Me.RecordsetClone.FindFirst "[PB_NAME] = '" & Me![cmbPB] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

'Pass the QueryDef to the query
Set qryDef = dbNm.QueryDefs("qryPBCustLevel")
qryDef.SQL = strSQL & " " & strOrder

'Open the Query
DoCmd.OpenQuery "qryPBCustLevel", acViewNormal

End Sub

Thanks, Steve. :confused:

View 2 Replies View Related

Queries :: Conditional Query To Post Result In Field And Filter Result Records?

Mar 5, 2014

I am working with Access 2010, on vista. What I have is a query made up of two tables, one product the other inventory. (see below) query.jpg

In the product table i have a field called "minimum reorder level". In the inventory table i have two fields one called "number in stock" and "number on order". What i want to happen is "number on order" to be filtered by the result, if the "number in stock", is less than "minimum reorder level", if it is, have the result placed in the "number on order" field. EG. if the "number in stock" = 2 and the "minimum reorder level" = 5 then 3 would be placed in the field "number on order" and only the second record from the query would be visible (see below) Query result.jpg The result of this would mean that the field "number on order" would be populated with the result and the and query would also use this to filter the record.

View 1 Replies View Related

Where Should I Post?

May 6, 2005

I have a very involved question regarding the export of data from and Access front end, SQL back end into multiple Excel Worksheets.

Where is the best place to post this in order to get maximum exposure to the great minds that cruise this board.

Regards

View 2 Replies View Related

Not Sure Where To Post This

May 17, 2005

I have a form that has several multiple choice question and i have also designed a table and update queries for the DB so far i can enter the values and then have them changed from the original to the values requested by my bos however i also need to find a way to make a report that will allow me to shot the percentage of people that chose each individual answer with anywhere from 2 to 10 possible choices on each question i see no logical way to do this....... help!

View 1 Replies View Related

My First Post

May 24, 2005

Hello every one
I am new here and this is my first post
I am trying to make overtime record for my company
I use the following feilds

field name .................... format
Start_Time ................... short time
End_Time ..................... short time
Total_Over_Time ........... short time

now when i use
Total_Over_Time = [End_Time]-[Start_Time]
I got correct answer

but

while i am trying to make monthly report
if Total_Over_Time is greater then 24 hours it shows me 1

means for 25 hours is shows 1

Please help me to overcome this problem

Thanks


Pehalwan

View 5 Replies View Related

Don't Know Where To Post This

Jul 8, 2006

I am developing an Access (2000) database to provide reporting data gathered from SAP and make it easily accessable for 12 analysts. The data set is HUGE, 5 months nearly a gig and will need at least 2 years worth, so I don't see any option other than using SQL as a back end. I have experiance using SQL server as the back end but have never had to develop my own server.

I do not have access to an existing server but do have permission to purchase SQL software, this is where I need the help. If anyone has suggestions, advice, links or other information I would be greatly appreciative.

Thanks in advance for your help.

“where I added information”

A lot of you have been reading this but no help.:eek: Did I use a poor title? I have used SQL as a back end but really need to know how to produce one out of thin air.

I ordered SQL 2005 off my company's IT store but when reading further it needs a special operating system, I think. Is this true? What do I need to have in order to provide a very large data set to a bunch of barely computer literate analysts?

These people are excited when they realize that vlookup can do more than one thing!! The concept of a union query would blow them away. I am frustrated with the competency of my co-workers but need to give them something that is idiot proof without letting them know that this is the object.

Currently they are having an SAP download sent to a specified share drive and running an Excel “macro”, moves a couple of columns an such, that puts it into a format that is semi-usable. This is totally inefficient for their needs but they don’t know it as yet.

What I am asking is how to take a fairly robust pc and make it a SQL server that will service a dozen or so people. What kind of operating system is needed and what sort of admin rights will be necessary to allow access to the desktop so they can get their data?

The IT help desk is very scary, not really understanding the requests presented. I haven’t been with the company very long but what I have garnered disturbs me I don’t believe the IT people have a clue.

I’ve been an Access developer for about 4 years now and know this is not an insurmountable obstacle. I am confident that SQL is the solution but haven’t ever had to create it from scratch before. Please, links or other suggestions are MOST appreciated.

View 1 Replies View Related

Queries :: Start Time - End Time Query

Nov 3, 2014

I have finger print machine and i already connect to it and get all log.then i tray to get data and here is the code that im using

SELECT Format(CHECKINOUT.CHECKTIME,"dd/mm/yyyy") AS CDate, IIf([CHECKINOUT.CHECKTYPE]=I,Format(CHECKINOUT.CHECKTIME,"hh:nn:ss ampm")) AS StartTime, Format(CHECKINOUT.CHECKTIME,"hh:nn:ss ampm") AS EndTime, USERINFO.USERID, USERINFO.Name, CHECKINOUT.CHECKTYPE
FROM CHECKINOUT INNER JOIN USERINFO ON CHECKINOUT.USERID=USERINFO.USERID
WHERE (((Format([CHECKINOUT].[CHECKTIME],"dd/mm/yyyy"))='10/04/2014'));

how i get end time due to CHECKTYPE]=O

View 1 Replies View Related

Dunno Where To Post This....

Sep 4, 2007

Preface: I don't know where to post this since I'm using a VBA executed SQL command or if this is a table issue.

I'm trying to import a .csv file into a "master" table of several .csv files. I've figured out how to link them and import them even though they have different field names, but the problem I'm running into is with serial numbers.

Some serial numbers are entirely numbers, while others are alphanumeric. When the field is set to numbers all of the parts (a different field) show up, but not all of the serial numbers are imported. When the field is set to text some of the parts are dropped, along with their associated serial numbers and then some of the serial numbers show up as scientific notation.

Any ideas on how to solve this problem?

View 2 Replies View Related

Does Anyone Know How To Post A Db On This Forum

Mar 17, 2005

could anyone please tell me how to post a database on this forum ive tried attachingit but it says file not suitable

View 4 Replies View Related

Database Example. Please Post

Nov 10, 2005

i need dbase example from all of u..especially example for newbie like me...i'm looking for example that update subform using combobox...

View 5 Replies View Related

Post Code Search

Aug 16, 2005

does anyone know if it is possible to add a post code checker/search to access, if so do you know of one which works. I want to be able to bring up an addess by post code/house number in the UK

View 2 Replies View Related

Validating A Post Code

Nov 29, 2006

HiBeen trying To Find A Way Of Validating A Postcode.But Getting No Where Being They Can Be Like CT1 1QX, CT11 2DT, CT11 12DT Act.Best I've done is to make sure there's a space and it starts and ends with a Letter.Any Help Advice Would be much AppreciatedMick

View 2 Replies View Related

Difference Between Post And Thread

Mar 15, 2007

Hi guys am not sure if i got dis in d correct forum (forgive me if not)

Just wanted 2 know what's d diff btwn a thread & a post (if d's any)

Noks

View 6 Replies View Related

Post-code On Form

Jan 23, 2008

Hallo,

I have a post code field on my form. What I want to do is, if a user enters a wrong code ... i,.e., not Post code format it alerts the user of post-code not in use. Please if there is any example of a database of this functionality usage or a way of doing it will be much appreciated.

I live in UK and the post codes down here are like E12 5AH ....

Many thanks

View 1 Replies View Related

Follow-Up To Previous Post...

Nov 15, 2004

Greetings,

I am just posting a follow-up on my previous post on designing functional forms. Telling by the lack of replies, my original question may have been long winded and tedious. Let me try to narrow my question and make it more concise.

In two tables connected by a one-one field name ProfileID, how can I set a new field in the second table (call it StepNo or procedureNo) so that it increments step numbers for each unique ProfileID record? Thus for each new Profile record created in the first table, a new form will allow the entry of X numbers of steps into the second table and automatically link the two records?

I hope that clarifies my problem. Thanks in advance.

View 3 Replies View Related

Post Code Validation

Apr 7, 2006

I have searched the forum for posts on the subject of UK postal code validation and found the reg expression that seems to be recommended for this.

I tried the expression but it will not accept this postal code? TS183AM

Like "(?:(?:A[BL]|B[ABDHLNRST]?|" & "C[ABFHMORTVW]|D[ADEGHLNTY]|E[CHNX]?|F[KY]|G[LUY]?|" & "H[ADGPRSUX]|I[GMPV]|JE|K[ATWY]|L[ADELNSU]?|M[EKL]?|" & "N[EGNPRW]?|O[LX]|P[AEHLOR]|R[GHM]|S[AEGKLMNOPRSTWY]?|" & "T[ADFNQRSW]|UB|W[ACDFNRSV]?|YO|ZE)" & "d(?:d|[A-Z])? d[A-Z]{2})"

View 14 Replies View Related

First Number In A Post Code

May 23, 2007

Hi,

I'm trying to isolate the first letter / letters of UK post codes.

Typically they are of the format ..

WS9 0JL

The obvious choice is left,2 but of course it's never that simple

some post codes are B1 7FH so left 2 gives me B1 but I need just the B

I can use Left 2 and the look at the second character to see if it is = "1" or "2" etc. but this seems a bit crude.

Is there a way I can find the position of the first number in a string (using the Instr function maybe)

That way i could Isolate the letter/s


Thanks


SBM

View 2 Replies View Related

Form Designs (Please Post Yours)

Jan 4, 2007

One thing that I personally think I'm bad doing is creating GUIs. I think my forms look pretty bad overall, and I'd like to get some ideas/pointers from some of the more experienced folks.

I've included a typical example.

View 1 Replies View Related

Post Code Validation

Mar 20, 2006

hello all
this thing is really bugging me im trying to come up with a post code validation and i have tried dozens, which should have worked really, but just havent so wondering if you guys knew any
examples of postcodes would be

BN3 8JH
BN41 8JH

the first and second characters have to be a letters
the 3rd has to be a number
the 4th is sometimes a letter (not always present)
then theres a space
then there has to be a number
letter
letter

any suggestive codes would be great, as none of mine have worked its in access

thanks

View 6 Replies View Related

Cities/Towns+Post Codes

Nov 21, 2005

I have a Contacts DB and at the moment I enter Cities/Towns and Post (zip) codes separately. I now want to set it up so I can select a city or town and have the appropriate post code fill it's own field without my intervention. Is this a case of cascading combo's or can I just bind a post code field to the city/town field? Can someone point me in the direction I need to go please?

View 1 Replies View Related

Disabling New Post On Mousewheel Scroll

Jan 17, 2006

Hi

I have a problem, when on a form based on a table, scrolling the mousewheel will by default change the post shown, how can I disable that event ???

Im using Access XP..

View 5 Replies View Related

Last Question For 24 Hours From When You Read This Post

Sep 30, 2006

Ok, I am getting well excited about what Access can do, and how the database I'm working on is coming along. It's the things that you guys find simple that I'm having problems with. So my question is:

I have fields called InitialAssessmentDate and ReviewDate. I want to be able to have a bold coloured label appear on the front page of a client record informing a user (when they access a clients record) when the client is due a review - usually three months after the Initial Assessment Date/and/or three months after the Review Date.

So far I have a couple of bold coloured labels that appear when individual client records open to advise users of other important stuff such as whether the client is high risk (for personal safety) or if the client needs a interpreter or signer: The code used for these two beauties is:

"Private Sub Form_Current()
Me.HighRiskLabel.Visible = Me.High
Me.InterpreterLabel.Visible = Me.Interpreter
End Sub"

Is it possible to do something similar for the date calculation?

Thanks in advance
Doug

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved