How can we help you today? How can we help you today?

Table function column names beginning with an @

CREATE FUNCTION fn_MyQuery ()
RETURNS TABLE AS RETURN
(SELECT 'test' [@Attribute], 'element' [Element]);
GO 
SELECT  fn_m.* FROM fn_MyQuery() fn_m
FOR XML PATH ('Test'), TYPE, ELEMENTS

In the above example SQL Prompt (6.1.0.67) identifies fn_MyQuery as having one parameter @Attribute, returning a single column Element.
rhodrie
0

Comments

2 comments

  • Aaron L
    Hi rhodrie,

    Thanks for reporting this, I can recreate it here and will look into a fix for you. Seems like we pull down the columns and parameters in a single query and then differentiate them based on if they start with an '@', which clearly doesn't work in this case!

    Thanks,
    Aaron.
    Aaron L
    0
  • Aaron L
    I think I've got a fix for this. Unfortunately it just missed out on making our 6.3 release which we're currently in the process of release testing, but I've made a private build for you and the fix will be included in a future release of prompt.

    Thanks again for reporting it!
    Aaron L
    0

Add comment

Please sign in to leave a comment.