Search results

  1. P

    Using OR in a query from a text box

    OK, so forgetting fruit so a second, what i am doing is this.. I have a table which containing lots of different jobs. They are a few different types such as planned works, reactive work, contract work, Adhoc work. I have started a database with this tables and people can run reports on it...
  2. P

    Using OR in a query from a text box

    Hi Plog, thanks for the very clear and concise explanation. Is there any way of achieving this as in my very very newbie thoughts my only solution is creating another query with additional columns that allocate a value. Such as... Apples and Pears, Apples and Bananas and Apples and Oranges and...
  3. P

    Using OR in a query from a text box

    Hi clever people. I wonder if you can help me I have a form with a text box and a query that has a criteria or [FORMS]![ThisForm]![ThistextBox] Is i enter say "apples" in the text box then the query shows be all records with the criteria of apples. If i enter "oranges" it shows me all records...
  4. P

    comparing 2 recordssets and updating

    Froth, It works. You sir are a genius !! I reentered all of you the code that you put in but put it in the SQL view rather than an expression builder and it works Thank you, Thank you, Thank you :-)
  5. P

    comparing 2 recordssets and updating

    Hi just tried that it it still doesnt blooking work ! I have copied your queries into mine and it still doesnt work. I have attached my database if you wouldnt mind having a look at what ive done wrong Btw im using access 2010 Again thanks for your help
  6. P

    comparing 2 recordssets and updating

    Froth again thanks for the help but when i put the first query in i get a "check the subquery syntax and enclose the subquery in parentheses" error ? I'm really sorry if im doing something silly but i have tried looking it up and im even more confused ?
  7. P

    comparing 2 recordssets and updating

    Froth. I really do appreciate your help but ive ran the code and its adding everything ! It wont let me stop it without breaking it and its current at half a gig !! Any thoughts ?
  8. P

    comparing 2 recordssets and updating

    Froth i really apprecdiate your help and have done everything you have said however when i run it i get runtime 3129 Invalid SQL statement expected delete, insert, procedure, select or update Have a done something wrong ?
  9. P

    comparing 2 recordssets and updating

    In case you want to help with the code :-P the tables are mainform and exordata fields are worksorderno -> jobno worksorderlineno -> lineno defect -> defectno
  10. P

    comparing 2 recordssets and updating

    Froth Yes sorry about the code. Can you please ellaborate ? What i am building is something that will be used by others so i am using macros and buttons for ease. The other spreadsheet is imported into a table and i then need to have the user press a button and anything that is not in the...
  11. P

    comparing 2 recordssets and updating

    Hi i have 2 recordset and i need to compare the two. If a record doesnt existing i need it to be added I have VBA that works but it seems very slow. Is there a better way of doing it Dim rs As DAO.Recordset Dim rs2 As DAO.Recordset Set rs = CurrentDb.OpenRecordset("SELECT * FROM...
  12. P

    Running a Macro from another form

    I have lots of textboxes that are update through a macro which is run when the record is opened. Its not just this though i want to have a form which has buttons which will run various macros . I figured that i should be able to call any macro from any place ? Is this possible ??
  13. P

    Running a Macro from another form

    Hi, I have 2 forms and a macro in Form1 which runs throught every record to update the records, however.. I would like to run this macro from the main form (Form2) I have tried docmd.openform "Form1" Run Macro but it doesnt work:banghead: Any ideas ?? Thanks
  14. P

    run macro from other form

    Hi all, Hopefully an easy one but i can seem to find an answer on the net I have a form with a button which when pressed need to run a macro which sits on a different form i have tried run macro ad do cmd but none of these work. Help please ?
  15. P

    Can you use CASE and INSTR together ?

    I think maybe i havent explained my self properly. The data comes from an outside source inported into a table. I cannot change the data so i need a way to pick out the data that i need. In order to do that i need INSTR. I just wondered if i can use CASE rather than having lines and lines of If...
  16. P

    Can you use CASE and INSTR together ?

    Pr, Thanks for that, but your case example doesnt use the INSTR command. The text could be anywhere in the string hence why i am using the INSTR command. I am familiar with case but was wondering if i can use CASE and INSTR together
  17. P

    Can you use CASE and INSTR together ?

    This is the sample code. I have changed the search string to hopefully make it clearer Basically the data i am being given is from a free text field and as such contains different spellings and ways of writting it. I am using Instr to search a string to find a number of different phrases and...
  18. P

    Can you use CASE and INSTR together ?

    Thanks PR, How would i use it, in this instance ? Phil
  19. P

    Can you use CASE and INSTR together ?

    Hi all, Newbie here. am writting some VBA for MS ACCESS and wondered if there is a better way of writting some code. I have a check for lots of different data in a string and wondered if i can use CASE or similar. Sample code reads... If InStr(1, Me.txt_sp, "Give & Take", 1) Then TM =...
Back
Top Bottom