Results 1 to 3 of 3

Thread: Help with SQL

  1. #1
    4 Star Lounger
    Join Date
    Mar 2005
    Location
    Leicestershire, United Kingdom
    Posts
    506
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Help with SQL

    Hi,

    I am getting a few problems with write conflicts with our access front end and sql back end and the guidance is to convert the bit fields from null to '0'.

    However I do not know how to do this within SQL server itself.

    My table is 'tblValuation' and the field is 'OMDone'

    I try to do an update query in access, but it already recognises the fields as 0. In sql, it recognises them as null when the value is not true so will not update.

    Going forward I hve now assigned a default value to new record created with this field as '0'

    Anyone help with the SQL to run?
    Best Regards,

    Luke

  2. #2
    Administrator
    Join Date
    Jun 2010
    Location
    Portugal
    Posts
    12,519
    Thanks
    152
    Thanked 1,398 Times in 1,221 Posts
    If you can run the query directly on the SQL Server database, the syntax would be something like this:

    Code:
    UPDATE tblValuation SET OMDone=0 WHERE OMDone IS NULL;
    Rui
    -------
    R4

  3. #3
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts
    From the Access side, you might try:
    Update tblValuation SET OMDone=False WHERE OMDone=False
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •