Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Why can I not get this mssql query to work?

Posted on 2007-11-28
7
Medium Priority
?
452 Views
Last Modified: 2012-08-14
I am getting this error below and wonder why and how to fix it can someone help please.
Warning: mssql_query() [function.mssql-query]: message: Unicode data in a Unicode-only collation or ntext data cannot be sent to clients using DB-Library (such as ISQL) or ODBC version 3.7 or earlier. (severity 16) in admin\closecase.php on line 25

Warning: mssql_query() [function.mssql-query]: Query failed in admin\closecase.php on line 25

Here is my code for that query from line 20- 25
$viewMyCasesII = mssql_query("SELECT     caseID, customerEmail, SysName, problemDescription, SysLoc, SysType, customerPhone, SRDATETIMESTAMP, Owner, OwnDept, CaseState,
                      chowned, submitTime
FROM         dbo.caseData
WHERE     (Owner = '$STAFFNAME') AND (CaseState = 'OPEN')
ORDER BY caseID");
0
Comment
Question by:lhaluska
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 21

Expert Comment

by:nizsmo
ID: 20367777
0
 
LVL 11

Expert Comment

by:jgordos
ID: 20367978
Change your column type from NTEXT to Text
0
 
LVL 11

Expert Comment

by:jgordos
ID: 20367985
i'm an idiot, i'm thinking 'nvarchar' in my head, and thinking 'text'.  change to varchar
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 1

Author Comment

by:lhaluska
ID: 20368070
Will I have to do this to every "nvarchar,ntext, nvar, and nchar'?
0
 
LVL 1

Author Comment

by:lhaluska
ID: 20368135
Oh and can I just change all of my columns in my table from "ntext" to just the 'text' if it has no unicode like foreign language text?
0
 
LVL 21

Accepted Solution

by:
nizsmo earned 2000 total points
ID: 20368153
ntext is for if you have unicode characters, you can use text if you have no unicode characters, you should be fine with just the english characters.
0
 
LVL 1

Author Comment

by:lhaluska
ID: 20368182
Thank you the help and for explaining my problem.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question