Search results

  1. C

    Using conditions in SQL...help!

    Hi there, sorry for not replying back right away, I took a few days off and away from this project. I do know about the month function and my problem is that I am going by year/month/week and not day. I suppose I could have used day 1-5 to represent each possible week but the rest of my database...
  2. C

    Using conditions in SQL...help!

    Final Solution: In working order. As a new field: GL : IIf(IsNull([tblGlnumber].[Gl Number]),(IIf([tblmonthinfo].[fldMonthnumber]=12 Or [tblmonthinfo].[fldMonthnumber]<4,"winter code","summer code")),[tblGlnumber].[Gl Number])
  3. C

    Using conditions in SQL...help!

    Update: I got the code to work properly. DCrake the code is flawless for those that do not have a valid GL number! So thanks a ton for that! There's just one piece of the puzzle that I cannot figure out. GL : IIf(IsNull([tblGlnumber].[Gl Number]),IIf([tblmonthinfo].[fldMonthnumber]=12 Or...
  4. C

    Using conditions in SQL...help!

    sorry about this, I think I've managed to make the situation far more confused than it needs to be. I think I understand what this code does now, correct me if I'm wrong; it shows you the results that have 'winter code' and 'summer code'? My problem is that the code is not actually applying...
  5. C

    Using conditions in SQL...help!

    Thats why I had that initial complicated mess of if statements. In simple terms I want: If theres a GL value for the job, put it in to the GL field. Otherwise, If month = dec to march, then put Winter Value into GL field. Else put summer value into GL field. I just don't understand the code...
  6. C

    Using conditions in SQL...help!

    Sorry, I'm confused too. What I am trying to do is have it place into the field "Summer code", "Winter code" or it's given GL value based on the job type and month. So that I'll have output like: Job Month Month# GL# Road1 Jan 1 GL1234 Private...
  7. C

    Using conditions in SQL...help!

    Hmm, I tried this and it has added two pop-up boxes asking for Winter Code1 and Summer Code1 parameter values. I this what we are trying to do?
  8. C

    Using conditions in SQL...help!

    In all other queries I have created I have used an , "*", [tblGLvalues]![GL Values] but I am unsure of how to make this work so that it places the given GL value if there is one.
  9. C

    Using conditions in SQL...help!

    Thanks to you both, I was having a horrible time trying to wrap my head around that code. IIf(IsNull([tblGlnumber].[Gl Number]),IIf([tblmonthinfo].[fldMonthnumber]=12 Or [tblmonthinfo].[fldMonthnumber]<3,"Winter Code2","Summer Code1")) is working, in the sense that I am not getting any...
  10. C

    Using conditions in SQL...help!

    This question is directly related to this thread: http://www.access-programmers.co.uk/forums/showthread.php?t=174814 I am trying to figure out how to code in a query so that I can apply one of two numbers to a record based on it's seasonal value (which is determined by the month given for each...
  11. C

    Inventory Pricing (Changes in prices)

    I do like the idea of using the average cost, as it is the most feasible in my mind. I haven't even got around to working on this part of my program yet, but I am glad that this topic has stirred up some intellectual consideration and I appreciate all your thoughts on how to do this.
  12. C

    Picking a number by Season

    * = [Tables]![tblJobCode]![jobcode] ...They're for GL numbers but it's simpler for explaination to call them jobcode because I will be doing similar things with other types of info.
  13. C

    Picking a number by Season

    Ok...so just an attempt to get the job code working I made a query and tried to use the following as a criteria, it obviously did not work, but it's a step towards what I'm trying to do: IIf(IsNull([tables]![tbljobcode]![jobcde]) THEN If [fldMonthnumber] = 12 Or [fldMonthNumber] < 4 THEN...
  14. C

    Picking a number by Season

    Ok here's my solution as far as I can get, I've created a table called tblmonthinfo, for each month i've given a numeric value... (1 to 12) and with relationship i've connected the spelt months together between tables. From here I believe I can query to associate the spelled month to its...
  15. C

    Picking a number by Season

    Is there a way to order a set of data to remain that way? IE. I have Months (Jan-Dec) with weeks (1-5) in them. If I could set it up so that by year it'd be from: Jan (week1), Jan (week2), etc. to Dec (week5). So that If I was looking for from May (Week2) to July (week1) it would show...
  16. C

    Picking a number by Season

    Once the system is finished my hope is that there will be a form that has the following fields to be put in: Month(listbox), Week, Year, Truck#(listbox), Jobtype(listbox), location(listbox), Hours spent. *All not tagged as a listbox are text boxes. If I must I can add a summer/Winter listbox...
  17. C

    Picking a number by Season

    That makes sense...just for the 'both' option I need to be able to determine via the month of input whether it's associated with 'jobcode-winter' or 'jobcode-summer'
  18. C

    Picking a number by Season

    Thanks for the response! Hmm, I have to think about how to do that. Because I'd have to create a togglable "Seasons" list box so that it could only come up on the input report for the jobs that can occur in both seasons...or maybe give 2 of the same values for a summer/winter option for the...
  19. C

    Picking a number by Season

    I've tried a few searches for something along these lines, but I cannot think of what to search for, if you read this and know of a previous conversation along these lines please pass along a link, or if you can help it'd be appreciated. The data: TableJobtype: I have a list of jobs that are...
  20. C

    NZ() IsNull... What does it all mean?!

    I decided my best bet is to make all the searchable fields required so that there would not be any nulls, I think this is the easiest solution. I'm going to work on setting up my queries and if I have any trouble getting them working properly I'll post to here. Thanks everyone!
Back
Top Bottom