How To Get Around This Error: 3:07 PM The operation failed with an error. Incorrect syntax near '.'

I created some SQL that worked fine in the Azure SQL Query Editor, but I kept getting an error when I was using it in Microsoft SQL Server module. I saw that in at least one place there was a missing space. So I asked ChatGPT to find the missing spaces and replace them with a Capital ‘X’ so it was easier to find. I manually put the spaces in and now it works fine. Is this a known / reported bug?

Thanks All,

Paul

Locations to replace with spaces:

  • After TripStop.PickupFlightNumberX
  • Before dbo.TripStopXLEFT JOIN
  • After ActivityType.ActivityTypeIDX
  • After LocationType.LocationTypeIDX
  • Before ORDER BY