List:General Discussion« Previous MessageNext Message »
From:Rhino Date:May 11 2006 3:51am
Subject:Re: PRINT statement?
View as plain text  
I am not familiar with the PRINT command so I don't know what it does. I 
played with MS SQL Server once for a couple of days a few years back and 
that is the only contact I've ever had with SQL Server.

If you can tell me what PRINT does, in detail, maybe I can suggest another 
alternative.

--
Rhino

----- Original Message ----- 
From: "Stephen Cook" <sclists@stripped>
To: "Rhino" <rhino1@stripped>
Cc: "MySQL List" <mysql@stripped>
Sent: Wednesday, May 10, 2006 8:09 PM
Subject: Re: PRINT statement?


> I've started using the SELECT with no other clauses but I am still curious 
> about a PRINT-like command.  It is for SQL scripts.
>
> Rhino wrote:
>>
>> ----- Original Message ----- From: "Stephen Cook" <sclists@stripped>
>> To: "MySQL List" <mysql@stripped>
>> Sent: Sunday, May 07, 2006 3:53 AM
>> Subject: PRINT statement?
>>
>>
>>> Is there a statement similar to PRINT in T-SQL (MicroSoft SQL Server)?
>>>
>>> It would be handy to debug some scripts.
>>>
>> If you're talking about a script that is running SQL, you can simply use 
>> the SELECT statement without any FROM, WHERE, ORDER BY, GROUP BY or 
>> HAVING clauses. For example:
>>
>>    select "Creating Foo table" as "Action";
>>
>> will produce the following output:
>>
>>    +----------------------+
>>    | Action                   |
>>    +----------------------+
>>    | Creating Foo table |
>>    +----------------------+
>>    1 row in set (0.00 sec)
>>
>> If you're talking about an OS script, you can use OS commands to display 
>> things. For example, I have some BASH scripts on our Linux server so I 
>> can use the BASH echo command, like this:
>>
>>    #!/bin/bash
>>    report_date=`/bin/date`
>>    echo "Report Date:" $report_date;
>>
>> to produce this output:
>>
>>    Report Date: Sun May 7 09:42:57 EDT 2006
>>
>>
>> -- 
>> Rhino
>>
>>
>>
>>
>
>
> -- 
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.392 / Virus Database: 268.5.5/335 - Release Date: 09/05/2006
>
> 



-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.392 / Virus Database: 268.5.5/335 - Release Date: 09/05/2006

Thread
PRINT statement?Stephen Cook7 May
  • Re: PRINT statement?Rhino7 May
    • Re: PRINT statement?Stephen Cook11 May
  • Re: PRINT statement?Rhino11 May
RE: PRINT statement?Quentin Bennett11 May
  • Re: PRINT statement?Rhino11 May
    • Re: PRINT statement?Stephen Cook12 May
      • Re: PRINT statement?Peter Brawley12 May
        • Re: PRINT statement?Stephen Cook12 May
          • Re: PRINT statement?Mark Leith12 May
            • MySQL commercial licenceAdam Lipscombe12 May
              • Re: MySQL commercial licenceDavid Logan12 May
                • RE: MySQL commercial licenceAdam Lipscombe12 May
                  • Re: MySQL commercial licencesheeri kritzer12 May
          • Re: PRINT statement?Peter Brawley12 May
            • Re: PRINT statement?Stephen Cook13 May