July 15, 2004 at 9:48 am
I have a frequent need to copy a list of items from MS Word 2002 into a SQL Query Analyzer window. Often, this list of items contains character strings that must have single quotes enclosing them. These single quotes will appear vertical in MS Word, but after they are copied into the Query Analyzer window they change to slanted quotes. Query Analyzer does not recognize these as quotes and they must be replaced with vertical single quotes within Query Analyzer before it will recognize them properly.
Does anyone know if there is a work around to this problem by changing some setting in either Query Analyzer or MS Word? I have tried changing fonts in both places, but this hasn't seemed to make any difference.
Thanks,
Frustrated by Microsoft
July 15, 2004 at 10:46 am
I'd guess you've not got ordinary quotes from Word - it does tend to use different characters and put in fancy quotes (single and double) rather than normal ones.
Can't think of a work around though think you'll need to do a search and replace.
July 15, 2004 at 11:01 am
Why not save the MS Word doc as a text file and open with notepad, wordpad, textpad, etc..???
This will have the same information that QA likes and will avoid the global search and destroy...
Good Hunting!
AJ Ahrens
webmaster@kritter.net
July 15, 2004 at 12:31 pm
This is because you have "Smart Quotes" replacement turned on in Word. If you go to the "AutoCorrect" settings you can turn it off and you should no longer have this problem. I have Word 2003 but here is how to turn it off for it. Should be similar for you.
Select the Tools menu
Select AutoCorrect Options
Click on the AutoFormat tab.
De-Select "Straight quotes" with "smart quotes"
Hit OK.
You can also do a search and replace from within Word for the characters by highlighting the character and hitting Ctrl+H.
Gary Johnson
Microsoft Natural Language Group
DBA, Sr. DB Engineer
This posting is provided "AS IS" with no warranties, and confers no rights. The opinions expressed in this post are my own and may not reflect that of my employer.
July 15, 2004 at 12:36 pm
Thanks AJ!!
While that certainly does work, I was hoping to avoid that extra step. I really don't have any need to save a version of the Word document in a text format otherwise. As my own version of a workaround, I've been doing a find and replace in either textpad or the SQL Query Analyzer window itself. I was just hoping to find a shortcut that would allow me to go directly from the Word file to Query Analyzer. Maybe there's just no way to avoid an extra step.
Thanks Again.
July 15, 2004 at 12:56 pm
Thanks Gary!!!. That did the trick.
It might work a little differently in Word 2002. For others that might want to make this modification, you need to take one more step.
Select the Tools menu
Select AutoCorrect Options
Click on the AutoFormat As You Type tab.
De-Select "Straight quotes" with "smart quotes" under "Replace as you type"
Thanks again.
January 20, 2006 at 4:19 am
Was looking for possible bug issues and thought I'd post something I spotted today...
When you execute a query in QA, a qag*.tmp file is created in Local Settings\Temp. When you next execute a query, the temp file is deleted and a new one created. I noticed a space issue on the C drive today and saw that a temp file was 2.9Gb in size and growing with every query. I closed down QA, re-opened it and the space went back to the OS.
Anyone seen this? Is this a known bug?
Clive
June 30, 2007 at 12:33 am
Today on my machine i also saw the same thing
From my client SQL i was running some queries on the Server. After some time qag .tmp files got created in the temp folder.
July 28, 2008 at 11:13 am
I am also noting the same thing where a qag*.tmp file is being created in the C:\Documents and Settings\ \Local settings\Temp\ directory whenever I run a query. This has recently caused some issues with space on the C: drive. Is there a way to turn this off?
Thanks,
Randy
October 14, 2008 at 4:50 am
It's a little after it happened (2006) to you, but we seem to see the same thing on a server we got. Did you already find a solution to this "qag" problem?
October 14, 2008 at 5:09 am
Hi there,
I (probably) found the solution to the problem:
In query analyzer, change (under Query) 'Results to grid' to 'Results in Text'. The temporary file will not be created anymore. Everything will be done in RAM.
The site where I found this, was:
http://community.ugiss.org/blogs/sgainz/archive/2008/01/27/cosa-devo-tenere-bene-a-mente.aspx
I translated it in:
when I do a select query with Management Studio or Query Analyzer, while the free space on the hard disk on which you installed the operating system decreases dramatically?
The problem is false in a temporary file that the query tool creates folder in "C: \ Documents and Settings \ \ Local Settings \ Temp" (or subfolder) to host the results that returns in the form grid. To be exact, temporary files of Query Analyzer are called qag *. tmp "and the Management Studio" tmp *. tmp "- where instead dell'asterisco there are 1 to 3 Characters" random ".
However, if this were to be a problem - eg. because there is already leaving little disk space - you might choose to display the results in text format, which would have been about RAM and then the Paging File. The latter, opportunities "moved" on a disk with greater storage (and maybe a little work dedicated I / O), would reduce even further the likelihood of saturation system disk.
March 4, 2009 at 3:32 pm
Hi,
The creation of qag*.tmp file seems to be a normal process when you run queries through SQL SERVER 2000 Query Analyzer.
To avoid this file keep growing, make sure you close the Query Analyzer after large queries being run. Since when you close the QA this file automatically get removed.
This applies to SQL SERVER 2005 as well. In this case you will notice a temp file being created each time you run a query. The file name shall be something like tmpD92E.tmp, tmpD92C.tmp, tmpD930.tmp etc.
Hope this help
March 4, 2009 at 11:36 pm
All,
We too had issue with the qag.tmp file.
The scenario: whe executed a job for deleting records in a particular table. The logfile of SQL server reached its max because of which the job failed to execute further. Now when we queried the table in question, we were able to see the qag.temp file being created in the User profile temp folder. Stopping the QA didn't deleted the qag.tmp file where as Closing the QA...deleted the qag.tmp file.I guess this might be because of some kind of memory leak / bug. I need to investigate the issue further. Any one has any thought on this please do let know!
Viewing 13 posts - 1 through 12 (of 12 total)
You must be logged in to reply to this topic. Login to reply