Skip to Content
author's profile photo Former Member
Former Member

userquery AND headerdata

Dear experts,

Could someone explain to me why a query like:

SELECT T0.[DocNum]
FROM [dbo].[ODLN]  T0
WHERE T0.Comments Like '%$[ORDR.DocNum.number]%'

works and this one:

SELECT T0.[DocNum]
FROM [dbo].[ODLN]  T0
WHERE T0.Comments Like '%$[$8.0.0]%'

doesn't?

The first query gives a correct DocNum (if I skipp the .number part it returns a value like N'204209' (inc. quotes) instead of just 204209).

The second query gets the same N'204209' value. If I add the .number for the last .0 I get a value like 204209,000000 which isn't what I want either.

I'm kinda lost figuring this out so any help would be appreciated.

René

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 10, 2010 at 05:18 PM

    Dear René,

    I have tested in 2007A db. Both are working if you change the 2nd one to $[$8.0.number].

    Are you sure it is not working?

    Thanks,

    Gordon

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.