Search results

  1. S

    SQL Query

    Hi, I am quite new to SQL Server and really need help running an SQL Statement. I am trying to select all records from one table and only those from another table which match, however I need to filter the second table first based on a user input. Anyone got any ideas on how I can do this...
  2. S

    Update query

    Is PartID a unique field? Because '(((Parts.PartID)=[Forms]![frmPOOrdersRec]![frmPOOrdersRecSubform].[Form]![PartID]));' is saying where partid is the part id in the subform. Are you listing multiple parts in the subform and you are finding this is only updating the selected one? Or is there...
  3. S

    Report Formating

    You will need to write a little bit of VBA for this, in the report detail (or whatever section your text box is in) write the following. If me.textboxname.value = "value" then me.textboxname.backcolor = 255 (255 = red) elseIf me.textboxname.value = "value2" then me.textboxname.backcolor = 0...
  4. S

    right or left in query?

    I think this is what you are trying to do. Off the top of my head the SQL should be something like the below, it will update the fields to Right(Field, InStr(Me.Text1, "Ex") + 2) but only where the field contins "ex", be careful though as this will replace anything with Ex in the field, you...
  5. S

    Opening a report instead opens a form (which opens a report)?

    Is the form opened from within the report vba module? i.e. Report_Open event This is one way it could be being done. Stu
  6. S

    Easy Parameter Qry

    I cant think of an easy way to do this, but if you look at the datepart("w", date) function you may be able to figure something out. This function will return the week of the year to which the date you pass it belongs. Shout if you need more help Stu
  7. S

    Update query

    Looks fine, can you post the SQL in your query? Stu
  8. S

    Cancel Report With SubReport

    You could 'bodge' you way round it by testing manually to see if the query behind the report has records before opening the report. If there are no records in the SQL dont bother. Dim dbs as Database Dim rst as recordset Dim strSQL as string set dbs = currentdb strSQL = "Query from sub...
  9. S

    SQL Server - Passing Parameters

    Hi, After years and years of working with Jet, I am now trying to use SQL Server backands and am having problems passing parameters to a stored procedure. How can I build a query which where I can say "WHERE ([AField]=""" & Forms!BlarBlaretc.value & """)" as I can in access because as I...
Back
Top Bottom