distal-attribute
distal-attribute
distal-attribute
distal-attribute

Strange problems interfacing with an MSSQL database

User, date Message
Written by Lynysys
1 year ago
Category: General
1 posts since Tue, 12 Feb 13
Hi All,

I happened upon the HeidiSQL program a few weeks back and I've been very impressed with the visual representation it gives to complex databases and the ease of management.

That said, I seem to be having some issues when modifying an existing MSSQL database.
Alot of the times the queries will fail and present various error messages.

I have to admit to being something of an SQL Newbie but know a smattering.
Often copying the query into the query editor and modifying them slightly will let them go through.

For example, is there a way to tell HeidiSQL to not put as many conditions after the WHERE part of an UPDATE query?
---
FAILS: UPDATE "database" SET "name"='Fred Blogs' WHERE "ID"=32 AND "Shoesize"='16' AND "Favourite Food"='chips" AND ........
WORKS: UPDATE "database" SET "name"='Fred Blogs' WHERE "ID"=32
---

So every time I update a field name, I must copy/paste the attempted query into the query editor and pare it to the end of the "ID" part (All the ID's are unique so I don't need it specify any more parameters to help SQL locate the record)

There are other issues around adding column names also. But I was wondering if any of this could be symptomatic of my using MSSQL rather than a MySQL Server?

Thank you in advance for any help you are able to give.

Kind regards,

Luke.
Written by ansgar
1 year ago
4940 posts since Fri, 07 Apr 06
This is not so strange as you might think. HeidiSQL just does not detect and use primary keys on an mssql database. See issue #2946 for more details.
 

Please login to leave a reply, or register at first.