PC Review


Reply
Thread Tools Rate Thread

Data shape command text contains a syntax error at or near position 106 in the command.

 
 
Bob
Guest
Posts: n/a
 
      11th Mar 2008
2007 .adp front ends connected to SQL 2005.
I frequently run into this when users are drilling into data on a DataSheet
form.
They may filter on a value in one column and when they try to apply the next
filter, they
get the above error. I use stored procs for all my forms. Procs using
input params in the
Form.InputParameters property seem to be the ones with the problems. I've
tried everything
I can think of. I'd really appreciate anyone that can shed any light on
this ...
thanks in advance,
bob.

 
Reply With Quote
 
 
 
 
Bob
Guest
Posts: n/a
 
      11th Mar 2008
I was able to come up with a fix for this. I am sharing this in case anyone
else
bumps into this problem.

Make the form a subForm on another form.
Add a control that will contain the name of the CurrentUser.
Make the Master property of subForm = to tbCurrentUser
Make the Child property of the subForm = UserName in the Table (Used as
Recordset for the subForm)

From the Menu Form.
the button that opens the above Form & subForm
--will 1st Delete all recs in the target table where UserName =
tbCurrentUser.
--Insert Into table using the user's params and tbCurrentUser.

Now you have a resultset for the subForm that is a table as opposed to a
query.
The table is filtered via the Master/Child relationship.
--The user can now Sort and apply as many filters as desired to the
resultset.

hope this helps someone...
Bob.


"Bob" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> 2007 .adp front ends connected to SQL 2005.
> I frequently run into this when users are drilling into data on a
> DataSheet form.
> They may filter on a value in one column and when they try to apply the
> next filter, they
> get the above error. I use stored procs for all my forms. Procs using
> input params in the
> Form.InputParameters property seem to be the ones with the problems. I've
> tried everything
> I can think of. I'd really appreciate anyone that can shed any light on
> this ...
> thanks in advance,
> bob.


 
Reply With Quote
 
mark.sjolin@hotmail.com
Guest
Posts: n/a
 
      9th Apr 2008
Passing a parameter to a stored procedure without using the full
syntax for the stored procedure parameter can cause this problem.

For example, me.InputParameters="1" might work for a while but may
suddenly begin causing the error you described.

Instead, use me.InputParameters="@parm=1" where @parm is the name of
the stored procedure parameter being passed to the form.
 
Reply With Quote
 
Bob
Guest
Posts: n/a
 
      14th Apr 2008
Thanks Mark..
I will give this a shot. It was driving me crazy. The workaround I
described works
perfectly but does require additional steps.
Thanks again for the reply.
bob.

<(E-Mail Removed)> wrote in message
news:c3d0afbf-5110-4e31-9fcd-(E-Mail Removed)...
> Passing a parameter to a stored procedure without using the full
> syntax for the stored procedure parameter can cause this problem.
>
> For example, me.InputParameters="1" might work for a while but may
> suddenly begin causing the error you described.
>
> Instead, use me.InputParameters="@parm=1" where @parm is the name of
> the stored procedure parameter being passed to the form.


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Command line option syntax error. Type Command /? for Help §ñühw¤£f DIY PC 2 19th Apr 2009 10:23 PM
Pivot Table Error Message - "Command Text not set for command obje =?Utf-8?B?SmVmZiBEaXZpYW4=?= Microsoft Excel Misc 0 7th Nov 2007 10:26 PM
Command line option syntax.error.type command for hlp/? =?Utf-8?B?amVyZW15?= Microsoft Outlook Discussion 6 29th Oct 2006 07:16 PM
Command Line Option Syntax Error - Type Command /? for Help Bob Breslin Microsoft Outlook Interoperability 2 14th Dec 2004 06:01 AM
Command text was not set for the command object error And DoCmd.OpenQuery tina Microsoft Access Getting Started 1 23rd Jan 2004 08:29 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:23 AM.