Help with Formatted search involving a UDF

I have a Formatted search which runns the following code:
exec xsp_nssItemLookup $[$38.256.0]
This search is on a udf of the Purchase order screen.  (256 is the item details field in the details.
The above query runs fine.  What I really want to do is to pass the contents of another UDF to the stored procedure.  The USF is called U_NSSItemID.  If I change my stored procedure to read:
exec xsp_nssItemLookup $[$38.U_NSSItemID.0] however it does not work.  I get blank results every time. 
I have also tried exec xsp_nssItemLookup $[POR1.U_NSSItemID.0]  which doesn't work either. 
I can't figure out what is wrong with my syntax.  I don't get any errors, just a blank value.
Thanks
don shields

Suda,
Thanks for answering so quickly.  To answer your question the data type is Alphanumber which I just figured out is the save as CHAR() in SQL.  My problem turned out to be that I needed to trim the spaces from my parameter.  I was getting values like "cover                         ", and I needted to get "cover".  Problem solved now.
Don

Similar Messages

  • Help with Formatted Search with Date

    Hi experts,
    I need help with the following query. In the PO item level, I want to take a user entered date and add 6 weeks to it. For example, after a user enters in a date in the field u_Date1, then U_date2 will populate with U_date1 + 6 weeks.
    I can get the query to copy the U_Date1 field. However, once I add 6 weeks (+42) then I get an internal error. Please advise.
    select $[por1.u_date1] + 42
    from por1 t0
    inner join t1 on t0.docentry = t1.docentry
    where t0.linenum = $[por1.linenum] and
    t1.docentry = $[opor.docentry]
    Thank you for your help.  i am on 2007A PL 47.
    Jane

    Hi Jane Liang ,
    you can try this : Select  DateAdd(day,42,$http://por1.u_date1 )  from por1 t0  .....
    regards
    H2

  • Problem With Formatted Search.

    Hi to all,
    I have linked a formatted search to a UDF that lies at row level in AP Invoice. This field is used to display the Sales  Order Price. The requirement is that from SO we create a purchase order and subsequently create a goods receipt and AP invoice.. Now in invoice it is showin perfectly fine whether it is copied from goods receipt or purchase order.. But in the purchase order and goods receipt screen this query will not work. And the same query used in AP invoice is being linked to these documents. Is there any work around for this?? Is it possible to run queries based on the form numbers?? If so ho do i pull the form number in the formatted search query??
    Please Help!!!!
    Regards
    Aris

    I recommend creating separate queries for each document.
    ie
    1 formatted search to lookup price on sales order from AP Invoice
    1 formatted search to lookup price on sales order from GRPO
    1 formatted search to lookup price on sales order from PO
    then change the lookup to pull fields from the document that you are using as a reference.
    when you are building the formatted searhes start by returning the values that are you are using as a reference. That way you are sure that you are pulling the correct information.
    Then layer in the lookup to the sales order.
    If you get stuck I recommend that you copy and paste the formatted search in SQL Server management studio and replace the variables refereces with real values.
    In my experience troubleshooting queries is more effective when using SQL Server management studio. (the error reporting is better).

  • Automatic formatted search for row udf item group autofill

    Dear All,
    I have a field udf field in the row of marketing document named u_itemgroupcode. I want that when an item is selected in any marketing document in the above udf automatically the Item Group code should come from the corresponding item OITB table.
    How to achive this through auto refresh formatted search.
    please help....!
    regards
    kamlesh

    Hi Kamlesh,
    ItemGroup code is available in OITM table itself. You could define the formatted search on the udf field
    with this query and define auto refresh with Item No.
    SELECT T0.[ItmsGrpCod] FROM OITM T0 WHERE T0.[ItemCode] =$ $38.1
    Regards,
    Vijay Kumar
    SAP Business One Forums Team

  • Help with fuzzy search (doesn't work if change order of certain 2 letters)

    Hi,
    need some help with fuzzy search. It's pretty simple - we use fuzzy search on varchar2 columns that contain first name and last_name. The problem is that i don't really understand why it can't find name in some cases.
    Say i want to search for 'Taekpaul'. Then
    where CONTAINS(first_name,'fuzzy(TAEKPAUL)',1) > 0 - works
    where CONTAINS(first_name,'fuzzy(TAEKPALU)',1) > 0 - works (changed order of the 2 last letters)
    where CONTAINS(first_name,'fuzzy(TEAKPAUL)',1) > 0 - doesn't work, finds 'Tejpaul' that is completely unrelated (changed 2nd, 3rd order)
    How can i make it find 'Taekpaul' even if i search for TEAKPAUL? Is it related to index? Like Text index should be created with some different parameters?
    Thanks!
    Edited by: Maitreya2 on Mar 3, 2010 2:08 PM

    Thanks, adding '!' worked :)
    Do you know where i can read more about '!' and other special characters? I think i didn't see anything like that here: http://download.oracle.com/docs/cd/B14117_01/text.101/b10730/cqoper.htm#BABBJGFJ
    I also started using JARO_WINKLER_SIMILARITY function that is actually better i think for what i do. But it's very buggy - sometimes Oracle crashes and kills connection when you try to use it.
    Ahha, it's here: http://download.oracle.com/docs/cd/B19306_01/text.102/b14218/cqspcl.htm
    So, ! is soundex. Whatever it means..
    Edited by: Maitreya2 on Mar 5, 2010 12:14 PM

  • How can i get totals in columns with formated searches

    How can i do this with SDK if it isn´t posible since formated searches

    This is not possible with formated searches.
    With SDK, depends on if it is Matrix or Grid, on if it is a system form/your own form. But basically, loop throw the form or datasource, and do the sumatory.
    Regards,
    Ibai Peñ

  • Read item code from Sales Order with formatted search

    hi,
    i'm tring to read tha values of the item or items of a sales order (before save it) with a formatted search.
    i have no problem to read the value of card code or cardname but i can't read the item's value.
    i tried with this [code]Select $[RDR1.ItemCode][/code]  (i found it on the forum) but it doesn't work.
    somebody can help me ?
    thank you

    Hi, Alessandro!
    I think the trouble is that you are trying to assign a FS to the header of the document. You are getting the information of the current row, so you have to bind a formatted search to some column of the "table - part" of the document.
    And also you can try:
    SELECT $[$38.1]
    38 - the value of "Item" (when you point a mouse to the cell, information you want from)
    1 - the value of "Column" (the same...)
    It will get an info of this cell in a current row.
    HTH!

  • Problem with formatted search in grid

    Hi all,
              I have a Grid with 3 columns in my user defind form. In that Grid,I used one one formatted search on column 2 based on the value of column 1.
               I mean when i was press 'SHFT+F2' on second column, it will execute the query based on value of  what we entered in the first column of the grid. How can i do this?? How can i fetch the value of first column in the formatted search??. Please help me.
    Thanx in Advance
      Oram.

    Hi
    write a query like this and assign formatted search on column2
    SELECT  ITEMNAME FROM OITM T0 WHERE T0.ITEMCODE = $[/$GRIDUID.COL1 UID.ROWNUM])
    regards
    Vishnu

  • Problem with formatted search on UDO Form

    Hi,
    I've created an UDO and in the lines I have the fields ItemCode and ItemName. In the ItemName field I have a formatted search configured the next way:
           -Search by Saved Query
               -QueryName
           -Auto refresh when existing altered column
               -ItemCode
           -Refresh regularly
    This formatted search works fine when I do <shift> + F2 in the field. But when I change the field ItemCode and get out of the field it doesn't execute the formatted search.
    Any ideas?
    Thanks in advance, regards
    Vanesa

    Hi Vanessa,
    Firstly (and I'm not giving lessons on sucking eggs) does this work when run as a query with the $ field replaced with a litteral value that you know exists in the table you're searching (surrounded by single quotes)?
    The reason I say this is that I have had a few where as opposed to giving an error I've been hitting shift+f2 with absolutely NO feedback via error messages.
    Which form is this within? How have you used the variable element in the query?
    Is it possible for you to show the query? Along with details on which form you're using it in?
    Hopefully be able to help with more info,
    Julian

  • Help on Formatted Search

    Hi Experts
    I would like to get some help on a formatted search I wish to created which will show the payment terms of a BP in a UDF on the Sales Order form.
    I have created a UDF and applied a formatted search to it which only brings in the record key of the payment terms:
    SELECT T0.[GroupNum] FROM OCRD T0 WHERE T0.[CardCode] = $[$4.1.0]
    Ideally I wish it to actually show me the Payment Group name from the OCTG table.
    Thanks in advance for your help.
    Thanks
    Jon

    Hi Jonny......
            You should use this query.......
    SELECT T1.[PymntGroup] FROM OCRD T0  INNER JOIN OCTG T1 ON T0.GroupNum = T1.GroupNum
    WHERE T0.[CardCode] =$[$4.0.0]
    apppply this to payment terms UDF in sales order.
    Regards,
    Best Rahul

  • Formatted Search Querry for UDF

    Dear All,
            My client is using SAP B1 2007 B PL10. Now I am facing a issue like, I have made a UDF in the A/P Invoice Form and hence made it mandatory. But when i make a UDF field as mandatory I have to write a particular default value.  Hence i have written default Value as 0.
          Now whenever i open the A/P Invoice Form,  the mandatory UDF Field is showing default value as 0. But I want to write a Formatted Search Based Querry in a way that the UDF Field should become Nil whenever I Open the A/P Invoice Form.
          Please guide me in writing the Formatted Search Querry by which the UDF Field which is having a Default Value as '0' should become Nil.
        Regards
    Hitesh Parsawala

    Hi Hitesh ,
    You have two option :
    1.Either donot make ur UDF mandatory at the time of creation
    Use sp_transaction notification to validate
    2. Define UDF manadatory at the neginning
    if user donot change the value , triggger approval procedure through FMS
      I think it is
    Select Distinct 'True' from tablename where <userdefined field =''i
    If user donot change, it is going to triger approval procedure
    <You can look for code in forum if that is not working >
    Hope this helps
    Bishal

  • Get matrix row data and put it into header field with formatted search ???

    Hi All,
    I ask your help concerning the following:
    On an invoice matrix I want to check all Itemgroup Codes of all items in the rows, if there are some rows' items with ItemGroupcode 101 and some others with anything else, then header field should be Y, otherwise N.
    My main problem is: how do I put a matrix row data to a header data with checking all rows in the matrix?
    A minor problem is that I can't get the formatted search to work on all rows when the formatted search is assigned to the user field in header.
    If I put the formatted search to a row field then the row field is filled with the proper value, but the same query assigned to the user field in header works only on the first row.
    What am I doing wrong?
    SELECT USEDPROD= CASE T0.ItmsGrpCod  WHEN 101 THEN Y ELSE N END FROM .[OITM] T0 WHERE T0.ItemCode = $[$38.1.0]
    (SBO 7.6)
    Any suggestions are welcome.
    Thanks.
    Bálint

    Dear Adele,
    Thanks for the answer. The major one cannot be solved. OK, I'll try to get a workaround.
    However I still do not understand why my query does not work in all selected rows, just in the first row, i.e. if I assign the query to a header field and I'm positioned in the first row it's OK, but when I add a new item to the second row or any of the next rows, the header field is not updated at all.
    Why is that so? Do you have any idea?
    Bálint

  • Help with intricate search and results display

    Hi All,
    I am looking for help with a problem I have, my knowledge on Numbers is limited, I have learnt a lot by trial and error but I do not know where to start on this problem.
    What I am trying to do is display result from sheet 1 onto sheet 2 when I enter the letters of the REFERENCE into cell C3. Below is an example of the result I am tring to achieve -
    SHEET 2
    Reference
    AB
    Reference
    SZone
    Parts
    LZone
    Parts
    AB10
    3
    75
    2
    100
    AB10
    3
    75
    2
    100
    AB10
    3
    75
    2
    100
    AB10
    3
    75
    2
    100
    AB11
    3
    75
    2
    100
    AB11
    3
    75
    2
    100
    AB11
    3
    75
    2
    100
    AB11
    3
    75
    2
    100
    AB12
    3
    75
    2
    100
    AB12
    3
    75
    2
    100
    AB13
    3
    75
    3
    75
    AB13
    3
    75
    3
    75
    AB14
    3
    75
    3
    75
    AB14
    3
    75
    3
    75
    AB15
    3
    75
    1
    200
    AB15
    3
    75
    1
    200
    AB16
    3
    75
    3
    75
    AB16
    3
    75
    3
    75
    AB21
    3
    75
    3
    75
    AB21
    3
    75
    3
    75
    AB22
    3
    75
    3
    75
    I have searched for AB by entering it in cell B3 on Sheet 2, an auotmatic search has been carried out on Sheet 1 and all the columns have been brought into sheet 2 with the corresponding data and placed under the COLUMN HEADERS. I have over 4000 lines on Sheet 1, although the most result that will ever be pulled through will be 150.
    When the data is pulled in I will need to do other calculation in the COLUMNS F, G and H so the data need to only be mapped to COLUMNS A to E.
    Also I want to be able to use this spreadsheet on my iPad.
    Has anybody got an idea/solution that will help.
    Thanks in advance.
    Ian

    Ian,
    We've had a recent report of troubles with large tables in the iOS version of Numbers, so you may want to consider ways to accomplish your goals without the full 4000-row set of data.
    I re-read the problem statement in your original post and see that I should have known that you were needing a solution for both platforms. But, I'm still not clear on what part you have figured out and what part you still need help with. We often refer to your second table as a "Breakout Table". There are different ways to program it. My favorite is to add a column to the main table that identifies rows that meet the transfer criteria and assigns them a serial number to help determine where they should go in the second table.
    Here's an example:
    In the new column on the right edge of the table T1, the expression is:
    =IF(ISERROR(FIND(T2 :: $A$1, A)), "", COUNT($F$1:F1))
    Note that the first cell in the Aux column is seeded with a zero.
    The expression in the body cells of the second table, T2, is:
    =INDEX(T1, MATCH(ROW()-1, T1 :: $F, 0), COLUMN())
    Note that the search term is to be entered into Cell A1 of table T2.
    Does this give you a start?
    Jerry

  • Help on Formatted search query

    Hello
    I have a formatted search that is the following to select line of marketing documents example
    select [$23.5.NUMBER]
    when the general setting display decimal separator as "," I have no problem but when decimal separator changes to "." then the formatted search is giving me error because result is [number.000000] too many zeros when it is without zeros with decimal separator set to ","
    How can I have the query run without zeros at the end when decimal is set to ","
    Thank you for your help

    Hi,
    Please advice exact field to check.
    Thanks & Regards,
    Nagarajan

  • Formatted Search - Sales Order - UDF

    Hi, I need to now if is possible, when I create a new Sales Order and I chage the Sales Employee on the drop down list I can catch the new sales employee selected and use it in a formatted search that is attached to a UDF, all this without saving the new created sales order...
    Is any way to catch a value in an active window and attach it to a UDF? for example the current selected sales employee?
    Thank you!

    Hi Gordon, its work's! many Thanks!
    Another question... you now if it is possible to update a field that have a FMS attached wen 2 event's happens?
    For example, I want to change the value of the commission % column when the user change the sales employee drop down list and when the user add a new line to the sales order... in this moment only works when I change the Sales employee, wen I try to add a new row it dont fill in the right commission %.       
    SELECT DISTINCT
    CASE
         WHEN $[ORDR.SlpCode]=6 THEN 6
         WHEN $[ORDR.SlpCode]=7 THEN 7
         WHEN $[ORDR.SlpCode]=8 THEN 8
         WHEN $[ORDR.SlpCode]=9 THEN 9
         WHEN $[ORDR.SlpCode]=-1 THEN -1
    ELSE 0     
    END
    FROM RDR1
    WHERE RDR1.ItemCode = $[RDR1.ItemCode]
    Thank you!

Maybe you are looking for

  • Finished DVD will not play

    Hi, I have burned my project to a DVD using FCPX. The problem is that it will not play in my DVD player (8 year old Sony player). It gets stuck on the first picture but the sound is running. I tried to play it on the Mac and on a PC, but the same pro

  • Web design workflow between Dreamweaver, Muse and Reflow?

    Do these 3 programs fit together in some kind of smooth workflow or does each program represents a different workflow based on the designer vs developer involvment on a project? I guess Im just confused why adobe has 3 programs for designers to creat

  • Download backups and file numbering issue

    A while back I lost a lot of stuff when a backup went wrong. I have been slowly trying to sort out the catalogues which has often meant importing stuff from the downloads backups. Anyway what seems to exist and is making life hard is that there are 2

  • APEX OAS HTTP SERVER etc

    Hi I'm not clear on architecture - for 10g Enterprise Edition, if I want to install APEX do I have to have an application server or can I just install the http server on the same box as the database? Is there anything wrong with this on a system that

  • Several issues - are they related?

    I've been experiencing several issues with my new IMac, and I wonder if they are related. First, the Adobe Flash plug in for Safari has been quitting unexpectedly. Then, Safari would start closing on its own. Finally, IPhoto also would suddenly quit.