TSQL Query to display First and Last Values of a GROUP as Columns - SQL Server 2008

Could someone please help with the TSQL to achieve the following: Every Employee has 2 records (From & To). Output has to display one record for each employee with From & To as columns.
Input
Empid
Type
Date
100
From
5/4/2004
100
To
6/2/2008
101
From
6/12/2003
101
To
6/2/2013
102
From
12/12/2012
102
To
5/3/2014
Output
EmpID
From
To
100
5/4/2004
6/2/2008
101
6/12/2003
6/2/2013
102
12/12/2012
5/3/2014
Thanks, Ashish Singh

SELECT empid,
MAX(CASE WHEN Type='From' THEN date END) from,
MAX(CASE WHEN Type='To' THEN date END) to
FROM tbl GROUP BY empid
Best Regards,Uri Dimant SQL Server MVP,
http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Consulting:
Large scale of database and data cleansing
Remote DBA Services:
Improves MS SQL Database Performance
SQL Server Integration Services:
Business Intelligence

Similar Messages

  • Query to find first and last call made by selected number for date range

    Hi,
    query to find first and last call made by selected number for date range
    according to filter:
    mobile_no : 989.....
    call_date_from : 25-april-2013
    call_date_to : 26-april-2013
    Please help

    Hi,
    It sounds like you want a Top-N Query , something like this:
    WITH    got_nums   AS
         SELECT     table_x.*     -- or list columns wanted
         ,     ROW_NUMBER () OVER (ORDER BY  call_date      ) AS a_num
         ,     ROW_NUMBER () OVER (ORDER BY  call_date  DESC) AS d_num
         FROM     table_x
         WHERE     mobile_no     = 989
         AND     call_date     >= DATE '2013-04-25'
         AND     call_date     <  DATE '2013-04-26' + 1
    SELECT  *     -- or list all columns except a_num and d_num
    FROM     got_nums
    WHERE     1     IN (a_num, d_num)
    ;This forum is devoted to the SQL*Plus and iSQL*Plus front ends. This question doesn't have anything to do with any front end, does it? In the future, you'll get better response if you post questions like this in the PL/SQL.
    I hope this answers your question.
    If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only), and also post the results you want from that data.
    Explain, using specific examples, how you get those results from that data.
    Always say which version of Oracle you're using (e.g., 11.2.0.2.0).
    See the SQL forum FAQ {message:id=9360002}

  • Message Mapping, First and last values in a CSV file

    I'm having problems with a Message Mapping that requires me to take the values from the first line in a CSV and the last line to calculate other values...
    The source message type in my mapping is as follow
    <MT_Message>
        <Header>                  1..1
             <ID>
             <StartDate>
             <EndDate>
       <Records>                 1...unbounded
               <Interval>
               <Number>
    I need to take the first row/occurence of Records and use this to calculate the Startime. I also need to take the last occurence of Records to calculate the stop time
    This is my CSV file content
    H     FORECASTS      20080101     20081231     17568
    D     20080101     1     1     66.29283
    D     20080101     1     2     61.1344
    D     20080101     2     1     61.1344
    In this case I need to take  the values 1     1 for the StartTime and 2    1 for the StopTime.
    How can this be done?

    Damien,
    Do  u have problem with mapping or content conversion. According to my understanding the problem is with content coversion. U can't take the first and last values in CSV file. Probably u can import all the values and during mapping u can seggregate the required structure alone.
    Best regards,
    raj.

  • How to find first and last date of a fiscal week using SQL

    Hello,
    I want information about FISCAL Week, means a Week based on ISO standard. I know format strings ‘IW’ or ‘IYYY’ gives fiscal week and fiscal year respectively from a given date. But I want to find the first and last date of a fiscal week. Say suppose I have a fiscal week is 2, and fiscal year is 2008, how to find the start and end date of the given fiscal week.
    Any kind of help would be greatly appreciable.
    Thanks,
    Prince

    davide gislon wrote:
    The following query evaluate the begin of a fisical week, where &year and &week are respectively the year and week you want to calculate.
    To evaluate the end of the week you have to add 6.
    Note that my database is set to have monday as day number 1 of the week, and sunday as day number 7; if your database settings are different you should modify the query accordingly.
    SELECT CASE TO_CHAR(TO_DATE('&year','YYYY'),'D')
    WHEN '1' THEN TO_DATE('&year','YYYY')+((&week-1)*7)
    WHEN '2' THEN TO_DATE('&year','YYYY')+((&week-1)*7-1)
    WHEN '3' THEN TO_DATE('&year','YYYY')+((&week-1)*7-2)
    WHEN '4' THEN TO_DATE('&year','YYYY')+((&week-1)*7-3)
    WHEN '5' THEN TO_DATE('&year','YYYY')+((&week-1)*7+3)
    WHEN '6' THEN TO_DATE('&year','YYYY')+((&week-1)*7+2)
    WHEN '7' THEN TO_DATE('&year','YYYY')+((&week-1)*7+1)
    END BEGIN_FISICAL_WEEK
    FROM DUAL
    Hope this is helpful.
    Cheers,
    Davide
    Edited by: davide gislon on 08-Jan-2009 07:19Your query does nothing you say it does. TO_DATE('&year','YYYY') returns first day of the current month for year &year. And the only reason it returns January 1, &year is that we are currently in January:
    SQL> select TO_DATE('&year','YYYY') from dual
      2  /
    Enter value for year: 2005
    old   1: select TO_DATE('&year','YYYY') from dual
    new   1: select TO_DATE('2005','YYYY') from dual
    TO_DATE('
    01-JAN-05
    SQL> As soon as we roll into February:
    SQL> alter system set fixed_date = '2009-2-1' scope=memory
      2  /
    System altered.
    SQL> select sysdate from dual
      2  /
    SYSDATE
    01-FEB-09
    SQL> select TO_DATE('&year','YYYY') from dual
      2  /
    Enter value for year: 2005
    old   1: select TO_DATE('&year','YYYY') from dual
    new   1: select TO_DATE('2005','YYYY') from dual
    TO_DATE('
    01-FEB-05
    SQL> alter system set fixed_date = NONE scope=both
      2  /
    System altered.
    SQL> select sysdate from dual
      2  /
    SYSDATE
    08-JAN-09
    SQL> But even if TO_DATE('&year','YYYY') would always return January 1, &year, or you would fix it to TO_DATE('0101&year','MMDDYYYY') it still would be wrong. ISO week rules are
    If January 1 falls on a Friday, Saturday, or Sunday, then the week including January 1 is the last week of the previous year, because most of the days in the week belong to the previous year.
    If January 1 falls on a Monday, Tuesday, Wednesday, or Thursday, then the week is the first week of the new year, because most of the days in the week belong to the new year.Therefore, next year:
    SQL> DEFINE YEAR=2010
    SQL> DEFINE WEEK=1
    SQL> ALTER SESSION SET NLS_TERRITORY=GERMANY -- enforce Monday as first day of the week
      2  /
    Session altered.
    SQL> SET VERIFY OFF
    SQL> SELECT CASE TO_CHAR(TO_DATE('0101&&year','MMDDYYYY'),'D')
      2  WHEN '1' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7)
      3  WHEN '2' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7-1)
      4  WHEN '3' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7-2)
      5  WHEN '4' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7-3)
      6  WHEN '5' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7+3)
      7  WHEN '6' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7+2)
      8  WHEN '7' THEN TO_DATE('0101&&year','MMDDYYYY')+((&&week-1)*7+1)
      9  END BEGIN_FISICAL_WEEK
    10  FROM DUAL
    11  /
    BEGIN_FI
    04.01.10
    SQL> SELECT TRUNC(TO_DATE('0101&&year','MMDDYYYY'),'IW') FROM DUAL
      2  /
    TRUNC(TO
    28.12.09
    SQL> 2 user10772980:
    Use:
    SELECT  TRUNC(TO_DATE('0101&&year','MMDDYYYY'),'IW') + (&&week-1)*7 FISCAL_YEAR_&&YEAR._WEEK_&&WEEK
      FROM  DUAL
    FISCAL_YEAR_2010_WEEK_1
    28.12.09
    SQL> SY.

  • Finding first and last members of a group set

    Is there any example how to use 'first' and 'last' functions in an sql query ?
    I have tried to execute a query like this on the scott.emp table :
    select deptno,min(sal),max(sal),first(sal) from emp group by deptno;
    but I always get this message:
    ERROR at line 1:
    ORA-00904: "FIRST": invalid identifier
    btw I use Oracle RDBMS ver 9.1.0.3 for Solaris in my server.
    tx for your help
    sjarif

    Syarif,
    The FIRST and LAST functions, which became available with 9i, are used to find the first or last member of a ranked set. I'm not sure exactly what you are trying to do, but I can show you a query that should work (I don't have 9i handy at the moment). This query should give you the departments with the highest (first) and lowest (last) aggregate salaries:
    select deptno,
    min(deptno)
    keep (dense_rank first order by sum(sal) desc) highest_sal,
    min(deptno)
    keep (dense_rank last order by sum(sal) desc) lowest_sal
    from emp
    group by deptno
    Is there any example how to use 'first' and 'last' functions in an sql query ?
    I have tried to execute a query like this on the scott.emp table :
    select deptno,min(sal),max(sal),first(sal) from emp group by deptno;
    but I always get this message:
    ERROR at line 1:
    ORA-00904: "FIRST": invalid identifier
    btw I use Oracle RDBMS ver 9.1.0.3 for Solaris in my server.
    tx for your help
    sjarif

  • Error 18452 "Login failed. The login is from an untrusted domain and cannot be used with Windows authentication" on SQL Server 2008 R2 Enterprise Edition 64-bit SP2 clustered instance

    Hi there,
    I have a Windows 2008 R2 Enterprise x64 SP2 cluster which has 2 SQL Server 2008 R2 Enterprise Edition x64 SP2
    instances.
    A domain account "Domain\Login" is administrator on both physcial nodes and "sysadmin" on both SQL Server instances.
    Currently both instances are running on same node.
    While logging on to SQL Server instance 2 thru "Domain\Login" using "IP2,port2", I get error 18452 "Login failed. The login is from an untrusted domain and cannot be used with Windows authentication". This happened in the past
    as well but issue resolved post insatllation of SQL Server 2008R2 SP2. This has re-occurred now. But it connects using 'SQLVirtual2\Instance2' without issue.
    Same login with same rights is able to access Instance 1 on both 'SQLVirtual1\Instance1' and "IP1,port1" without any issue.
    Please help resolve the issue.
    Thanks,
    AY

    Hello,
    I Confirm that I encountred the same problem when the first domain controller was dow !!
    During a restarting of the first domain controller, i tried to failover my SQL Server instance to a second node, after that I will be able to authenticate SQL Server Login but Windows Login returns Error 18452 !
    When the firts DC restart finishied restarting every thing was Ok !
    The Question here : Why the cluster instance does'nt used the second DC ???
    Best Regards     
    J.K

  • Set out of range value to a time datatype in sql server 2008

    Hi,
    I have a variable set to time datatype in SQL server 2008. I need to set a value more than 24 hrs to that. Is there any way? I get an error like Conversion failed when converting date and/or time from character string. .Below is my scenario
    declare @QuietBeginTime time
    SET @QuietBeginTime  = (SELECT value FROM #RCQD where id=8)
    ---------This has a value like '24:45'
    Print @QuietBeginTime
    Please help me.
    Deepa

    declare @QuietBeginTime time
    SET @QuietBeginTime  = (SELECT value FROM #RCQD where id=8)
    ---------This has a value like '24:45'
    Print @QuietBeginTime
    Above is my scenario. Your example is fine, But main thing is i want to set a value to a variable, That
    i am unable to do
    Deepa

  • To display first and last dates of a month

    I have the date format in 10 Mar 10.
    My requirement is when ever I select the any date in the dashboard for whole month it should display whole month results.
    I got query in obiee101.blogspot.com.but if I use that sometimes it is not returning the last day results. Any body please give me the query to display results for first day and lastday?
    Ex:if I select any day in the drop down of the prompt it should display whole month results
    If I select either 1 mar 10,2 mar 10,30 mar 10.....
    It should give the results for whole month of march.
    Can you please provide me the query for last month also?
    If I select march date in date print want to display whole march results in one column,previous month results in other column
    Anybody help me to get this done?

    Yes, you are correct. In John's SQL for last day of the month, if the "last day of the previous month" ends on the 30th, than "adding one month" will result in the 30th of the following month. But if the following month has 31 days, you miss that day.
    Use this for the last day of the current month.
    TIMESTAMPADD(SQL_TSI_DAY, -1,TIMESTAMPADD(SQL_TSI_MONTH,1,TIMESTAMPADD(SQL_TSI_DAY,1,TIMESTAMPADD(SQL_TSI_DAY, DAYOFMONTH(CURRENT_DATE)*-1, CURRENT_DATE))))
    The above SQL will ensure that you will always get the last day of the "current month" regardless of how many days are in the previous or current month.

  • First and last values of this month

    Hi ,
    In my reporting I want to calculate average value based on amount.
    Avg = ( Starting amount of this month + Ending amount of this month) / 2.
    How can i get the starting value and ending value for one field "Amount".
    I changed the <b>amount</b> properties as Sum, Last value and based 0calday.
    but for the same amount how can I get the starting value.
    (NOTE: Starting value is not equal to the last month last value).
    The data is coming based on day wise.
    Suggest me ...
    Thanks in advance....
    Regards
    Rajesh

    Dear Rajesh,
    Can you tell me which cube you are working with, and what is the key figure ?
    What you can do is have a RKF which will have a selection variable for fiscal year period for the current month(which could be a user entry and mandatory entry).
    Now create a copy of the above RKF and use a off set of -1 for the variable fiscal year period.
    now the valu you get from the first RKF will be the month end balance and the value you get for the second RKF will be the closing balance of previous month, which is nothing but the opening for the user inputed month.
    Now you can create a CKF to get the average.
    Hope the above helps, If yes please assign reward points
    regards
    Venkata Devaraj

  • Cisco SPA-504G: Retrieving Broadsoft Personal directory does not display first and last name

    Hi,
    We are using the Cisco SPA-504G on BroadWorks Release 17.sp3. We are using the feature to lookup the different BroadWorks directories through the 'dir' button on the Cisco phone. For configuration you have three choices for telling the phone which directory it needs to retrieve:
    - Personal
    - Group
    - Enterprise
    This can be found by going to Voice -> Phone -> Broadsoft Settings in the web GUI of the phone (admin & advanced mode).
    When retrieving the Enterprise or Group directory everything is working OK. I can see the names and the corresponding phonenumbers of the users.
    When retrieving the Personal directory I only see the phonenumbers and not the names of the entries. This is probably due to the fact that the XML output of the Personal directory is different compared to the Enterprise/Group directory. Personal directory is like:
    <Personal><startIndex>1</startIndex><numberOfRecords>2</numberOfRecords><totalAvailableRecords>2</totalAvailableRecords><entry><name>Name X</name><number>0123456789</number></entry><entry><name>Name Y</name><number>0987654321</number></entry></Personal>
    Result of requesting: http://xsp.domain.tld/com.broadsoft.xsi-actions/v2.0/user/[email protected]/directories/Personal
    Group directory is like:
    <Group><startIndex>1</startIndex><numberOfRecords>1</numberOfRecords><totalAvailableRecords>1</totalAvailableRecords><groupDirectory><directoryDetails><userId>[email protected]</userId><firstName>FirstName</firstName><lastName>LastName</lastName><hiranganaLastName>LastName</hiranganaLastName><hiranganaFirstName>FirstName</hiranganaFirstName><groupId>BroadWorksGroupID</groupId><extension>9999</extension></directoryDetails></groupDirectory></Group>
    Result of requesting: http://xsp.domain.tld/com.broadsoft.xsi-actions/v2.0/user/[email protected]/directories/Group
    As you can see the name of a user in the Personal directory is defined by <name></name> and the name of a user in the Group directory is defined by <firstName></firstName> <lastName></lastName>.
    So it looks like the phone is not capable of parsing the XML output of the Personal directory request. And to me that looks like a bug.
    Anyone that can acknowledge?
    Kind regards,
    Bart Derks
    RoutIT B.V.
    edit: We are running firmware 7.4.9c.
    Message was edited by: Bart Derks

    Our upcoming release scheduled for the end of this month should resolve this issue.  There were a number of fixes in this particular area that were made.

  • Last one month jobs execution time in sql server 2008 r2

    Dear Friends,
    We configured replication between three servers two are publishers and one subscriber for two publisher.
    my question is daily basis one job running on subscriber end it truncate and insert the data every night .
    unfortunately today job was failed I observed in jobs view history. but client requirement manually run the job and data dump into the table. but I want know its previous execution time as per that I will run the job in production hours but in jobs view
    history showing only today's fail job history. how to find the last execution time .
    note: yesterday job was successfully completed.
    Message
    Executed as user: NT AUTHORITY\SYSTEM. Cannot initialize the data source object of OLE DB provider "SQLNCLI10" for linked server "server name". [SQLSTATE 42000] (Error 7303)  OLE DB provider "SQLNCLI10" for linked
    server "server name" returned message "Unable to complete login process due to delay in opening server connection". [SQLSTATE 01000] (Error 7412).  The step failed.
    mastanvali shaik

    But what about to that particular job ? what is the name of the job ? Please assign that job name in the below script and check .. Its sure that history is not exist for that particular job anyway for your confirmation please use the below scripts and try...
     make sure to add the name .. when was the last backup taken for your system databases ?
    WHERE    JOB.name = 'Your JobName'  -- Add your job name..
    SELECT      [JobName]   = JOB.name,
                [Step]      = HIST.step_id,
                [StepName]  = HIST.step_name,
                [Message]   = HIST.message,
                [Status]    = CASE WHEN HIST.run_status = 0 THEN 'Failed'
                WHEN HIST.run_status = 1 THEN 'Succeeded'
                WHEN HIST.run_status = 2 THEN 'Retry'
                WHEN HIST.run_status = 3 THEN 'Canceled'
                END,
                [RunDate]   = HIST.run_date,
                [RunTime]   = HIST.run_time,
                [Duration]  = HIST.run_duration
    FROM        sysjobs JOB
    INNER JOIN  sysjobhistory HIST ON HIST.job_id = JOB.job_id
    WHERE    JOB.name = 'Your JobName'
    ORDER BY    HIST.run_date, HIST.run_time
    Raju Rasagounder Sr MSSQL DBA

  • ODBC functions SQLExecDirectW and SQLExecute functions return error:"DIAG [22001] [Microsoft][SQL Server Native Client 10.0]String data, right truncation (0) "

    Problem Description:
    ODBC functions SQLExecDirectW and SQLExecute functions return error:”DIAG [22001] [Microsoft][SQL Server Native Client 10.0]String data, right
    truncation (0) “. When we enable tracing in the ODBC administrator, in the SQL.log we see that values for the arguments: ColumnSize, BufferLength, and StrLen_or_IndPtr of ODBC function SQLBindParameter are not being displayed.
    Environment Used:
    OS: Microsoft Windows Server 2003 R2 Standard x64 Edition.
    Complier: Microsoft Visual Studio 2008 SP1 for x64.
    Database: Microsoft SQL Server 2008
    MDAC: Microsoft Data Access Components SDK 2.8
    Note: This problem is seen only in our 64bit application. However, in 32bit
    SQLExecDirectW and SQLExecute functions return successfully.
    As we could not find the values of 6<sup>th</sup>, 9<sup>th</sup> and 10<sup>th</sup> arguments(ColumnSize,
    BufferLength, and StrLen_or_IndPtr) passed to
    SQLBindParameter in the ODBC traces for 64bit, we are not sure whether the values for the above mentioned arguments are received correctly by SQLBindParameter or not. This information would help us to debug further. So, could you please let us know why
    these values are not displayed.
    1)Here is the extract of the SQL.log file for 32bit where the values for SQLULEN , SQLLEN and SQLLEN* are displayed properly:
    PR0CNFG 1028-15f0 ENTER SQLBindParameter
    HSTMT 0x006FBDD8
    UWORD 1
    SWORD 1 <SQL_PARAM_INPUT>
    SWORD -8 <SQL_C_WCHAR>
    SWORD -9 <SQL_WVARCHAR>
    SQLULEN 23
    SWORD 0
    PTR 0x0595EBBA
    SQLLEN 46
    SQLLEN * 0x05A5FB00
    2)Here is the extract of the SQL.log file for 64bit where the values for SQLULEN , SQLLEN are not displayed properly and
    SQLExecDirectW function return error:”DIAG
    [22001] [Microsoft][SQL Server Native Client 10.0]String data, right truncation (0) “. :
    PR0CNFG a78-fe4 ENTER SQLBindParameter
    HSTMT 000000000431D2F0
    UWORD 1
    SWORD 1 <SQL_PARAM_INPUT>
    SWORD -8 <SQL_C_WCHAR>
    SWORD -9 <SQL_WVARCHAR>
    SQLULEN SQLULEN SWORD 0
    PTR 0x0000000005364EFA
    SQLLEN SQLLEN
    SQLLEN * SQLLEN *
    PR0CNFG a78-fe4 EXIT SQLBindParameter with return code 0 (SQL_SUCCESS)
    HSTMT 000000000431D2F0
    UWORD 1
    SWORD 1 <SQL_PARAM_INPUT>
    SWORD -8 <SQL_C_WCHAR>
    SWORD -9 <SQL_WVARCHAR>
    SQLULEN SQLULEN SWORD 0
    PTR 0x0000000005364EFA
    SQLLEN SQLLEN SQLLEN *

    Hi Nalsr,
    From my research, I found:
    "[Microsoft][ODBC SQL Server Driver]String
    data right truncation" error may be returned from a call to
    SQLBindParameter if the size of the string parameter being used is greater than the size of the column being compared to. In other words if the
    string size of the <expression> to the left of the <comparison_operator> is less than the
    string size of the <expression> to the
    right, ODBC may return this error.
    The resolution is to make the string size of the <expression> to the
    right of the <comparison_operator> less than or equal to the
    string size of the <expression> on the left.
    It is difficult to track down this type of problem when third party development applications are being used. ODBC Trace can be used to help determine if this problem is occuring.
    Here is an example where the customer has submitted a query "select count(*) from type1 where type1 = ?", type1 is varchar(5) and the
    data type being passed by the application is char[9].
    Here is the relevant portion of the trace. The following information from the "exit" of SQLDescribeParam
    SWORD * 0x0095e898 (12)
    UDWORD * 0x0095e880 (5)
    Maps to the following with the actual value in parenthesis - SQL_VARCHAR Size 5:
    SQLSMALLINT *DataTypePtr
    SQLUINTEGER *ParameterSizePtr
    The "exit" value from SQLBindParameter provides the following
    information:
    SWORD 1 <SQL_PARAM_INPUT>
    SWORD 1 <SQL_C_CHAR>
    SQL Data Type SWORD 12 <SQL_VARCHAR>
    Parameter Size UDWORD 5
    SWORD 0
    Value PTR 0x0181c188
    Value Buffer Size SDWORD 5
    String Length SDWORD * 0x0181c103 (9)
    The string length parameter is the length of the
    string being bound to the parameter, in this instance there is a size mismatch which results in the SQLError and the SQLErrorW with the message "[Microsoft][ODBC SQL Server
    Driver]String data
    right truncation" .
    Hope this could be helpful.
    Best regards,
    Halin Huang

  • CF8 and MS SQL Server 2008

    Hi,
    I'm wondering if anyone else has run into this issue. We are porting an older CF app to CF8 and upgrading our db at the same time. Our old model is CF 6.1 using MS SQL Server 2005 and our new model is CF8 using MS SQL Server 2008.
    I'm having the following issue....
    We have an application form where people apply to jobs, they can either type their text in, or copy and paste (usually from MS Word). On the back end we use CF ToBase64 and then ToBinary functions to convert the data to store it in a Blob field in the db.
    No code changes have been done.
    If the user copies and pastes into the form field and it contains MS bullet points, in our old model they are stored correctly, under the new model they are not. When I look at that candidates data on the web page I see ? marks where the bullets should be. Querying the db field directly and doing the necessary conversions to get the data back into string format, I can see that the field actually contains question marks.
    I have tried using Adobe's recommended change of using the CharsetDecode and CharsetEncode functions - these do not make any difference.
    Has anyone else encountered this problem?

    You may test encode / decode the input data (only testing the ToBase64 function), or may be just display the input, without encode base 64, to check the encoding management. I guess it comes from the input page.

  • SMS_SRS_REPORTING_POINT - Error retrieving folders with SCCM 2012 and SQL Server 2008 R2 SP2

    Hi:
    According to all the Reporting Services logs my Reporting Point was setup correctly.  When I try and run any report I see the entries below in the srsrp.log on the SQL Server.  The report names show up in the Console but when I right any of the
    listed reports I get errors and no report runs.
    I am running SQL Server 2008 R2 SP2 on a remote server.  SQL is installed on its own server.  There is no firewall between the Configuration Manager server and SQL Server.
    Thanks.
    Mark
    (!) Error retrieving folders - [A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance
    name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because
    connected host has failed to respond.)].   SMS_SRS_REPORTING_POINT
    1/25/2013 9:15:07 AM    4532 (0x11B4)
    No folder configuration information found.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:07 AM   
    4532 (0x11B4)
    Next security configuration at [1/25/2013 9:22:42 AM]
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:07 AM   
    4532 (0x11B4)
    Root Folder exists     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:07 AM   
    4532 (0x11B4)
    Successfully checked that the SRS web service is healthy on server DBSCCM.LOCAL    
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:07 AM 
    4532 (0x11B4)
    Waiting for changes for 1 minutes  
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:07 AM   
    4532 (0x11B4)
    SRSRP registry key change notification triggered.    
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:16 AM   
    4532 (0x11B4)
    Waiting for changes for 1 minutes  
    SMS_SRS_REPORTING_POINT 1/25/2013 9:15:16 AM   
    4532 (0x11B4)
    Timed Out...     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM   
    4532 (0x11B4)
    Reporting Services URL from Registry [http://dbsccm/ReportServer/ReportService2005.asmx] 
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM 
    4532 (0x11B4)
    Reporting Services is running
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM   
    4532 (0x11B4)
    Retrieved datasource definition from the server.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM   
    4532 (0x11B4)
    Retrieved datasource definition from the server.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM   
    4532 (0x11B4)
    Updating data source {5C6358F2-4BB6-4a1b-A16E-8D96795D8602} at ManagedDesktops_MD1 
    SMS_SRS_REPORTING_POINT 1/25/2013 9:16:16 AM 
    4532 (0x11B4)
    (!) Error retrieving folders - [A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance
    name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because
    connected host has failed to respond.)].   SMS_SRS_REPORTING_POINT
    1/25/2013 9:17:40 AM    4532 (0x11B4)
    No folder configuration information found.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:17:40 AM   
    4532 (0x11B4)
    Next security configuration at [1/25/2013 9:22:42 AM]
    SMS_SRS_REPORTING_POINT 1/25/2013 9:17:40 AM   
    4532 (0x11B4)
    Root Folder exists     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:17:40 AM   
    4532 (0x11B4)
    Successfully checked that the SRS web service is healthy on server DBSCCM.LOCAL    
    SMS_SRS_REPORTING_POINT 1/25/2013 9:17:40 AM 
    4532 (0x11B4)
    Waiting for changes for 1 minutes  
    SMS_SRS_REPORTING_POINT 1/25/2013 9:17:40 AM   
    4532 (0x11B4)
    Timed Out...     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM   
    4532 (0x11B4)
    Reporting Services URL from Registry [http://dbsccm/ReportServer/ReportService2005.asmx] 
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM 
    4532 (0x11B4)
    Reporting Services is running
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM   
    4532 (0x11B4)
    Retrieved datasource definition from the server.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM   
    4532 (0x11B4)
    Retrieved datasource definition from the server.     
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM   
    4532 (0x11B4)
    Updating data source {5C6358F2-4BB6-4a1b-A16E-8D96795D8602} at ManagedDesktops_MD1 
    SMS_SRS_REPORTING_POINT 1/25/2013 9:18:40 AM 
    4532 (0x11B4)

    Hi:
    Windows Firewall is off on both systems.
    I can ping the Configuration Manager server from the SQL Server by netbios name, ip address and fully qualified domain name.   I can ping the SQL Server from the Configuration Manager server by netbios name, ip address and fully qualified domain
    name.
    I have uninstalled and installed the Reporting Point Service a couple of times and everything looks fine according to the logs after the install finishes but these errors only appear each time I try and Run a report.
    Mark

  • How can I display the first and last name using a paramater as employee ID?

    Hi SAP,
    I have a parameter that is called {? Employee ID}.   What I want to do is display the first and last name based on the employee ID value entered in {? Employee ID} in the page header of the report.  Right now, when I put the following formula in the page header only some pages get the right result while other pages dont....
    if table.employeeid = {? Employee ID} then
    table.firstname" "table.lastname
    It appears as though if the first record in the details section on the beginning of each page happens to be the employee under {? Employee ID} then it prints it correctly, if it isn't I get a null value in the page header.
    Anyone have any ideas?
    Z

    Hi Try this,
    Whileprintingrecords;
    if ={?EmpID} then
    Also check the option "Default values for null" in the formula editor.
    Regards,
    Vinay

Maybe you are looking for

  • Wily Introscope is not running in Solution Manager 7.1

    Hello Experts, wily Introscope is not running in solution manager system, below error getting in log, solution manager is running on windows server and how to start wily in windows. 8/23/14 11:58:50.088 AM IST [INFO] [WrapperSimpleAppMain] [Manager]

  • Looking for Motion 5 template designer ?

    I am in desperate need of someone who can design a FCPX/Motion5 template for a community TV show. I need a F1/NASCAR style results list with: POS:     DRIVER:     CAR:     TIME Up to 10 lines on a 1080 screen 25p. I have tried to make one myself but

  • Graphic manager Oracle 9i on linux Red Hat 8.0

    I would like to know if someone can help me about the way that i can start the Graphic manager of Oracle 9i on Linux Red hat 8.0, because after i installed Oracle, the manager starts but when I shut down my computer it never appeared again. Can you h

  • Change in CST form 3% to 2%

    Hi, Our Company has recently go-live with MySAP-ECC-6.0 & TAXINN. The Govt of India changed CST form 3% to 2% recently. I have two options to change the same. a) By Creating New Tax Code -- this is OK with New PO but what to do with existing PO. b) I

  • Error in Application because of missing right in LV-Link

    hello, I´am trying to build a application from my program. i use labview 2010 and LV-Link. when i start the applicationbuilder i get the error 8 by copy in AB_Engine_Copy_Error_Files.vi->AB_Application.lvclass:Copy_Error_Files.vi->AB_Application.lvcl