开发者

How can a SharePoint SQL connection be set to query by the current login name?

I have a SQL table that needs to be queried by the login name. So, using SharePoint designer I successfully created a database connection, but I can't use the properties exposed by Profile nor Session as input parameters because they are not supported (A dialog pops up with a message indicating this)

How else can I query a SQL da开发者_Python百科tasource by using the current login?

-Edit

To create the data connection, proceed as follows

  1. Open the data source library
  2. Expand database connections and click on connect to a database
  3. Enter the database settings
  4. Select "specify custom Select, Update, Insert, and Delete"
  5. Click on Edit Command
  6. Add a parameter and select Profile and enter UserName as the property name

An error will follow stating that this is not supported.


Unfortunately, you don't give many details but I think you're looking for the LOGON_USER Server Variable: Data View / Data Form: Parameters You Don’t Know About.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜