entering parameter criteria MS Query

Hope someone can help. I’m trying to extract data from a SQL Server 2005 into 
Excel, using a parameter criteria in MS Query. If I use criteria in a field 
with an integer data type it works fine. If I use a field with an NVARCHAR 
data type (which is the one I want) I get a “Syntax Error” message. There 
seems to be no way of entering criteria into this type of field which MS 
Query will accept.  If I enter james it defaults to N’james‘, which works as 
syntax criteria in SQL Server Management Studio 2005, but not in MS Query. 
What am I doing wrong?!
0
Utf
4/29/2010 11:46:01 AM
excel.misc 78881 articles. 5 followers. Follow

0 Replies
1288 Views

Similar Articles

[PageSpeed] 38

Reply:

Similar Artilces:

Cell format newbie query
I have a worksheet where all the cells in a column are formatted as text but there are numbers entered in the column. Changing the format of the column, or even any individual cell, to number, does not remove the triangle in the cell top left corner. What should I be doing to fix the situation? Thanks Brian Tozer Hi Brian! One quick way: Select a blank cell Copy Select the range with data in it Edit > Paste Special Add OK You'll note that this converts the format of the selected range to General -- Regards Norman Harker MVP (Excel) Sydney, Australia njharker@optusnet.com.au Exc...

Why is Actual Work updated when entering time into Work Field?
We're using MS Project 2007 and seeing that sometimes when time is entered into the Work field for a task, that task's Actual Work is updated to the same value entered in the Work field. This happens to multiple resources, but only on some of their tasks and not on others. For example, for the weeks of 1/24 and 1/31, whatever hours I schedule (enter in the "work" cell in the Resource Usage View) for a given task also appears in the "actual" cell. The tasks are setup up differently. Some are Fixed Work, some are Fixed Duration. I believe all have the e...

Query for a report
Good Morning. I am trying to figure out how to calculate the number of days between two dates. I have a table callled events. That table has event date, event type, event outcome. I am pretty new to Access and need help. For example a defendant will have an Advisement Date (AA as stored in the table) and say a Preliminary Hearing date (PH). When i enter information I will enter the date, event type and the event outcome will be (PD for Pending, CN for Continued, or CP for completed). For example Case Number 10-12345 will have an AA on 01/05/10 which is Completed and a Prelimina...

Excel 2003 spreadsheet. I enter the any number and it is entered.
If I enter a number into a cell it is put in like a decimal. For example, if I enter 10 it is put in as .1 500 is entered as a 5 Thank you Mary Mary, Goto Tools>Options and on the Edit tab you should see The Fixed Decimal Places box checked. Uncheck it. -- HTH RP "maryu" <maryu@discussions.microsoft.com> wrote in message news:65C0E0FB-43F3-4F34-8A86-FBA3F02EC9B1@microsoft.com... > If I enter a number into a cell it is put in like a decimal. For example, if > I enter 10 it is put in as .1 500 is entered as a 5 > Thank you > Mary ...

Outlook: I keep getting MS Word appearing interrupting work
Hi, Have installed outlook 2007 standard, all ok. Except, Outlook uses MS Word as it's email editor, which I like. But there appears on my system a MS Word 'frame' which seriously gets in the way of working. sometimes it appears behind outlook and blocks the background, sometimes it i selected instead of outlook and so I cannot select anything in outlook without re-focussing on outlook. It's highly annoying. Can anyone tell me how to get rid of it? I still want to use word as my email editor, but don't want the ghost frame that it creates...... Thanks. Hugh. Outl...

Filter records by date in subform by date entered in mainform.
Hello, I've spent 3 days trying to understand what I'm doing wrong.....Here is the summary of my problem. I have a form named 'frm_EfficiencyStats' and a subform within the form named 'qry_Total hours subform' (the subform is based on a query). The form contains a text box (for date) which is bound to a table 'tbl_EfficiencyStats'. I would like to be able to enter a date in the text box on my form, and display the records in the subform based on the date I entered in the text box. The subform will only pull records from my table based on the date. Here are th...

Nested Filters in MS Project
Is there a way to do Nested Filtering in MS Project. I know and have used simultaneous filters in Primavera, like applying two or more filters in a boolean "And" or "Or" conditions. How do I do that in MS Project. I have separate filters for segregating data and would like to use a combination of different filters to get to the report I need. Please advice... -- Thank you IMS addendum/clarification to above question... I do not want to use a single Filter and get lost in the nesting filtering conditions as they will be too many, and I'm would ...

Printing Query Promt Parameters in a report
I have a QUERY in Access 2003 that promts the user for a START and END date. Is there a way to display the inputed START and END date from the QUERY in a REPORT without having to retype it in the report? On Mon, 14 Dec 2009 15:29:01 -0800, vegman wrote: > I have a QUERY in Access 2003 that promts the user for a START and END date. > Is there a way to display the inputed START and END date from the QUERY in a > REPORT without having to retype it in the report? Let's assume the exact query prompt is [Start Date] and [End Date] Add an unbound text control to the Re...

convert to ms access add-ins
My company is converting from Office 97 to Office 2000 and I frequently used the feature in Excel 97 of "converting to ms access". Our customer support has done a full load of 2000 and have tried to manually add the "access link add in program" and it shows that it is loaded but it is not appearing under the Tools menu. They have tried reinstalling and everything else they can think of but can not figure out what why it will not load. Any suggestions? Put it in the add-in folder, restart excel, do tools>add-ins and check it there.. -- Regards, Peo Sjoblom "...

left join query is not working
I have created a temp table that store ms project plans in an excel format. Each week, I import the updated plans into the temp table and then I then run an update query that updates my master table with the lastest information in the temp table - the join query The problem is that not all the updates are being included in the master. What options do I have? I would like to update the master with the lastest imported records but it doesnt always happen. Here's the query UPDATE [Temp Table] LEFT JOIN [Master Transfer Table] ON ([Temp Table].ID= [Master Transfer Table].ID) ...

how to enter simple list and sum
using excel 2002 with an xp sp2 system how would I enter a simple list of positive and negative numbers and then create a cell with the sum of these values? if the list would look like this 0.58 -1.22 1.79 -0.56 -0.92 the output would look something like 0.58 0.58 -1.22 -0.64 1.79 1.15 -0.56 0.59 -0.92 -0.33 John In B1 enter =A1 In B2 enter =B1+A2 Copy down to B5 Gord Dibben MS Excel MVP On Wed, 16 May 2007 06:34:13 +0300, "John" <johnj@multipl.es> wrote: >using excel 2002 with an xp sp2 system >how would I enter a simple list of positive and negative...

How to "un-install" MS Outlook Express "trial offer"?
I received this offer to "try" MS Outlook Express as my email. I'm running Vista Business. I just emailed MS Support to please terminate the program. NOW: Do I have to wait for them? Or can I get rid of it myself? I don't know who does what! I've used them for years, but don't know &^%$ about them. -- jjgunn Please note that this forum is for questions about MS Office Access, which is the database program in the MS Office Suite. You might try searching out, and posting your question into, a forum dealing with MS Outlook Express. George "jjgunn&q...

Resource Units for Tasks entered in PWA differs than tasks entered in Project 2007
Hello, I have an ePM user asking why if he enters a project task in PWA does it not check the resource max units allocation the same way as when he enters a task in Project Professional. For example: You have a project where resource A is 50% allocated. When you create a task in Project Professional for this resource, the resource allocation is set to 50%. Create a task under the same project in PWA, submit and approve the task. Open project professional and view the task information for the task entered in PWA, why is the resource allocation set to 100% instead of 50% set for th...

1 Field and 2 Criteria
I'm new to Access but very fluent in Excel so bare with me on this. What I have is a query I'm trying to create where I have a Problem Code(numeric) and a Fix Code(numberic). Each of these codes have a Long Description in a table just for these codes. However, this table has several "TABL"'s within it. To get descriptions for a Problem Code the TABL field must equal "101". To get descriptions for a Fix Code the TABL field must equal "303". This is a problem because when I write the query I have each code read out on a row but I can ...

Enter formula by code.
Hi All can anyone help. I cant seem to get this to work. I keep getting run time error 1004 application or object defined error. Public Sub TLIdentify() finalrow = Worksheets("INV Bookings").Range("B65536").End(xlUp).Row Worksheets("INV Bookings").Range("AV26:AV" & finalrow).FormulaR1C1 = "=IF(OR(RC[-38]>0,RC[-32]>0,RC[-26]>0,RC[-20]>0,RC[-14]>0,RC[-8]>0,RC[-2]>0),VLOOKUP(RC4,'Team Summary'!R4C3:R16C4,2,0),"")" End Sub -- Regards and Thanks for any assistance. Francis Brown...

Headings to rows in a query
Hi I have a number of columns in the query and I created one column called data from and I would like to put those headings to rows. How to do it? Example Cost C Cost D Data From 1122 Cost C 1122 Cost D Can you advise how to do it? -- Greatly appreciated Eva Usually you do something like this in labels on the form or report which uses your query as a recordsource. Please explain why you want to do this in your query. Steve santus@penn.com "Eva" <Eva@discussions.microsoft.com> wrote in message news:40EBA712-466B-...

MS Money Report
I'm runing MS Money 2004. I can not get a report to display. Not sure what I'm doing wrong any tips? In microsoft.public.money, Cracker Jacks wrote: >I'm runing MS Money 2004. I can not get a report to display. Not sure what >I'm doing wrong any tips? Try resetting the report. Click Customize and then Reset. Thank you. You are true Money Pro! Software any way muhahahaaa....it worked. "Cal Learner-- MVP" <via_newsgroup@please.tnx> wrote in message news:7pmed093bf04s2qum4dsb4ea11go87lef8@4ax.com... > In microsoft.public.money, Cracker Jacks wrot...

Entering a dollar amount w/out having to enter the decimal
What is the formula to have Excel automatically enter the decimal so all I have to enter is the numbers? It's one of the options you can specify. In Excel 2007, it's: Excel Options...>Advanced>Automatically insert a decimal point Regards, Fred "Julieanne" <Julieanne@discussions.microsoft.com> wrote in message news:3AABE398-3B77-4ACD-8938-05ED7F5CC58E@microsoft.com... > What is the formula to have Excel automatically enter the decimal so all I > have to enter is the numbers? ...

Search criteria #2
Hello I am using Outlook 2000. In the contact view, is it possible to add a search for telephone numbers when performorming a search. Does outlook 2003 allow searches in the telephone numbers? if 2000 doesnt. Regards Ken ...

Edit and save query criteria
I have 2 Select queries where the results criteria changes on a yearly basis for 2 fields. There are 6 tables referenced in the queries. Only 2 tables referenced with 1 field each where the criteria would be changed. How could a user edit and save these changes? These are very Novice users of a database who would not have access to the open database. This was a homegrown database, but now trying to make it useable for others who have little to no experience. Thanks for any and all suggestions. -- DN One way would be to use a parameter prompt where the users are prompte...

Anyone have MS Project Plan for Planning/Executing a Golf Tourname
I created one a long time ago according to the PGA recommended guidelines and checklists. It was a lot of work so I'd like not to have to reinvent the wheel... Hello MEHSJH, If you have the one you created before, have you considered basing a new project on that file? I hope this helps. Let us know how you get along. Julie Project MVP Visit http://project.mvps.org/ for the FAQs and additional information about Microsoft Project On 1/14/2010 3:04 PM, MEHSJH wrote: > I created one a long time ago according to the PGA recommended guidelines and > checklists...

append query 03-03-08
i am trying to append from one table (NewItems) to another(Main), but get an error saying it can't append 975 [of 4000] records due to key violations. The target table (Main)has a composite primary key made of date and itemnumber. All the items to be added have a new date that doesn't exist in Main. The append query is left joined on NewItems ItemNumber, so that all records from NewItems table should go into Main table. What am i not seeing? Why are 975 items being rejected? thanks. doh! i was using an expression to add , so i had to use a max query instead of the Main table...

Bio Scan for MS-RMS & MS-POS
Several of my clients would like to add Bio Scan to their existing or pending Point of Sale systems. This is becoming an industry standard and would add value to our offerings. ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open the suggestion in the Microsoft Web-based Newsreader and then click "I Agree" in the message pane. http://www.microsoft.com/Businesssolutions...

entering time #2
hello all.. wondering if there is any way to do this... I have a column formatted for time as in this format 12:00 when entering a time it is cumbersome to have to enter the hour, then a colon, then the minutes. Is it possilbe to simply enter a 4 digit number such as 1245 and have it show up as 12:45 ?? thanks so much... I've found this group to be irreplaceable... glen in orlando Enter your times without colons in column A and put this formula in column B =(A1-RIGHT(A1,2))/2400+RIGHT(A1,2)/(24*60) and format column B for "Time" in the form you want it. Tod "Glen i...

Date in criteria expression
The following is giving me an error message "data type mismatch in criteria expression": If Not IsNull(DLookup("ClassDate", "tblSCC", "([ClassDate] = '" & .ClassDate & "')")) Then... Is there something tricky about a date field that I don't know about? Rip On Tue, 2 Oct 2007 17:47:49 -0400, RipperT wrote: > The following is giving me an error message "data type mismatch in criteria > expression": > > If Not IsNull(DLookup("ClassDate", "tblSCC", "([ClassDate] = '&...