Forum Replies Created

Viewing 15 posts - 511 through 525 (of 1,479 total)

  • RE: SELECT data for today's date

    What is the type of the column TimeStarted? Is it a string or datetime?

    Adi

  • RE: Nested XML Explicit encodes the xml to string

    The FOR XML clause was introduced in SQL Server 2000. At that time SQL Server didn’t have the XML data type, so it returned a regular string. ...

  • RE: Information_schema.Table Privelege

    Can you make sure that your user can actually work with those tables? Maybe the user is also part of role that has deny permissions on the tables. ...

  • RE: Information_schema.Table Privelege

    As far as I know everyone has permissions on those views, but you can only see tables that you have permissions to work with. When you say that you...

  • RE: Error Executing the Convert Function. Please assist.

    When you use style number 113, you get the date and time with spaces in it. When you use style 112, you don’t have spaces in the results. ...

  • RE: XML extraction from database

    Maybe I don’t understand what you need. Maybe you don’t use the correct query. Maybe you don’t open the correct fie. In any case in the...

  • RE: Need to Delimiter from right to left

    Not sure that I understood what you want. If I understood you correctly then this is the way to do it:

    DECLARE @NextString NVARCHAR(40)

    DECLARE @pos INT

    DECLARE @NextPos INT

    DECLARE @String NVARCHAR(40)

    DECLARE...

  • RE: XML extraction from database

    The query that you got does exactly what you asked for. The element sentdate is the child of saftyreport and when you minimize the element saftyreport, you don’t...

  • RE: XML extraction from database

    If you want to get the results that WayneS showed you, you can use the fallowing query:

    SELECT

    'en' AS "@lang",

    messagetype AS "ichicsrmessageheader/messagetype",

    messageformatversion AS "ichicsrmessageheader/messageformatversion",

    messageformatrelease AS "ichicsrmessageheader/messageformatrelease",

    messagenumb AS "ichicsrmessageheader/messagenumb",

    messagesenderidentifier AS "ichicsrmessageheader/messagesenderidentifier",

    messagereceiveridentifier...

  • RE: Dynamic query in a function

    User defined functions have some limitations. One of those limitations is that you can’t use dynamic SQL in it. This is by design and there is no way...

  • RE: Export old data

    There isn’t correct and wrong way. You can work with insert select and linked servers. Another way is to work with SSIS and write your own package....

  • RE: common table expression(cte)--query

    It is very hard to understand your question. Pleas fallow the URL in my signature to see how to write a question. If you’ll fallow the direction at...

  • RE: Date Time Convertion

    One way of doing it is like that:

    select convert(char(8),getdate(),103) + ' ' +

    CASE WHEN datepart(hh,GETDATE()) > = 12 THEN CONVERT(varchar(10), dateadd(hh,-12,getdate()),8) + 'PM'

    else CONVERT(char(10),getdate(),8) + 'AM' end

    Of...

  • RE: Alter column

    It’s been a while since I last worked with replication on SQL Server 2000, but as far as I remember modifying table that is published is very limited. You...

  • RE: To switch or not to switch

    I have to admit that I failed the question and I was surprised. When I saw the correct answer I couldn’t believe it. Every single option that was...

Viewing 15 posts - 511 through 525 (of 1,479 total)