Results 1 to 5 of 5
  1. #1
    Techno is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    May 2023
    Posts
    31

    ON UPDATE CASCADE Syntax error in CONSTRAINT clause

    Both-



    1. ON DELETE CASCADE
    2. ON UPDATE CASCADE

    give Syntax error in CONSTRAINT clause when executed. What is the mistake?

  2. #2
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,003
    What are the constraints on the tables concerned?
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

  3. #3
    June7's Avatar
    June7 is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,967
    Are you trying to build this SQL in query object? Review https://stackoverflow.com/questions/...delete-cascade

    Post your code if you still need help.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  4. #4
    Techno is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    May 2023
    Posts
    31
    Thank you for the replies.

    I was trying to run these DDL commands in SQL view of query. I'll try to run these in VBA.
    What type of SQL commands can't be run in SQL view? Thank you again for your help.

  5. #5
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,003
    Please post the exact whole SQL statement you are using.
    What you have shown so far wouldn't work, and is incomplete.
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

Please reply to this thread with any new information or opinions.

Similar Threads

  1. CHECK CONSTRAINT causing Syntax Error?
    By AishlinnAnne in forum SQL Server
    Replies: 18
    Last Post: 09-13-2016, 12:42 PM
  2. syntax error in from clause
    By jskamm in forum Access
    Replies: 2
    Last Post: 09-18-2012, 09:13 AM
  3. Syntax Error in FROM clause
    By cjohnston in forum Queries
    Replies: 2
    Last Post: 02-15-2012, 07:33 AM
  4. Incomplete Syntax Clause (syntax error)
    By ajetrumpet in forum Programming
    Replies: 4
    Last Post: 09-11-2010, 10:47 AM
  5. On delete cascade fails in constraint clause
    By Victor EGBE in forum Queries
    Replies: 0
    Last Post: 03-02-2009, 09:52 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums